18
18
push :
19
19
branches :
20
20
- master
21
- - ' v*-branch'
21
+ - " v*-branch"
22
22
pull_request :
23
23
merge_group :
24
24
workflow_dispatch :
25
25
workflow_call :
26
- inputs :
27
- run-codeql :
28
- required : false
29
- type : boolean
26
+ inputs :
27
+ run-codeql :
28
+ required : false
29
+ type : boolean
30
30
31
31
concurrency :
32
- group : ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
32
+ group :
33
+ ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name ==
34
+ ' pull_request' && github.event.number) || (github.event_name ==
35
+ ' workflow_dispatch' && github.run_number) || github.sha }}
33
36
cancel-in-progress : true
34
37
35
38
env :
47
50
volumes :
48
51
- " /:/runner-root-volume"
49
52
- " /tmp/log_output:/tmp/test_logs"
50
- options : --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
53
+ options :
54
+ --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
51
55
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
52
56
53
57
steps :
@@ -57,26 +61,34 @@ jobs:
57
61
run : echo "$GITHUB_CONTEXT"
58
62
- name : Dump Concurrency context
59
63
env :
60
- CONCURRENCY_CONTEXT : ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
64
+ CONCURRENCY_CONTEXT :
65
+ ${{ github.ref }}-${{ github.workflow }}-${{
66
+ (github.event_name == 'pull_request' &&
67
+ github.event.number) || (github.event_name ==
68
+ ' workflow_dispatch' && github.run_number) || github.sha }}
61
69
run : echo "$CONCURRENCY_CONTEXT"
62
70
- name : Checkout
63
71
uses : actions/checkout@v4
64
- - name : Try to ensure the directories for core dumping exist and we
72
+ - name :
73
+ Try to ensure the directories for core dumping exist and we
65
74
can write them.
66
75
run : |
67
76
mkdir /tmp/cores || true
68
77
sysctl -w kernel.core_pattern=/tmp/cores/core.%u.%p.%t || true
69
78
- name : Checkout submodules & Bootstrap
70
79
uses : ./.github/actions/checkout-submodules-and-bootstrap
71
80
with :
72
- platform : linux
81
+ platform : linux
73
82
- name : Initialize CodeQL
74
83
if : ${{ inputs.run-codeql }}
75
84
uses : github/codeql-action/init@v3
76
85
with :
77
86
languages : " cpp"
78
87
- name : Setup Build
79
- run : scripts/build/gn_gen.sh --args="chip_config_memory_debug_checks=true chip_config_memory_debug_dmalloc=false"
88
+ run :
89
+ scripts/build/gn_gen.sh
90
+ --args="chip_config_memory_debug_checks=true
91
+ chip_config_memory_debug_dmalloc=false"
80
92
- name : Run Build
81
93
run : scripts/run_in_build_env.sh "ninja -C ./out"
82
94
- name : Run Tests
@@ -94,11 +106,15 @@ jobs:
94
106
- name : Run Build Without Detail Logging
95
107
run : scripts/run_in_build_env.sh "ninja -C ./out"
96
108
- name : Set up Build Without Progress Logging
97
- run : scripts/build/gn_gen.sh --args="chip_detail_logging=false chip_progress_logging=false"
109
+ run :
110
+ scripts/build/gn_gen.sh --args="chip_detail_logging=false
111
+ chip_progress_logging=false"
98
112
- name : Run Build Without Progress Logging
99
113
run : scripts/run_in_build_env.sh "ninja -C ./out"
100
114
- name : Set up Build Without Error Logging
101
- run : scripts/build/gn_gen.sh --args="chip_detail_logging=false chip_progress_logging=false chip_error_logging=false"
115
+ run :
116
+ scripts/build/gn_gen.sh --args="chip_detail_logging=false
117
+ chip_progress_logging=false chip_error_logging=false"
102
118
- name : Run Build Without Error Logging
103
119
run : scripts/run_in_build_env.sh "ninja -C ./out"
104
120
- name : Set up Build Without Logging
@@ -117,7 +133,7 @@ jobs:
117
133
if : ${{ inputs.run-codeql }}
118
134
uses : ./.github/actions/perform-codeql-analysis
119
135
with :
120
- language : cpp
136
+ language : cpp
121
137
# OBJDIR on linux is > 10K files and takes more than 50 minutes to upload, usually
122
138
# having the job timeout.
123
139
#
@@ -143,7 +159,8 @@ jobs:
143
159
volumes :
144
160
- " /:/runner-root-volume"
145
161
- " /tmp/log_output:/tmp/test_logs"
146
- options : --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
162
+ options :
163
+ --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
147
164
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
148
165
149
166
steps :
@@ -153,22 +170,27 @@ jobs:
153
170
run : echo "$GITHUB_CONTEXT"
154
171
- name : Dump Concurrency context
155
172
env :
156
- CONCURRENCY_CONTEXT : ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
173
+ CONCURRENCY_CONTEXT :
174
+ ${{ github.ref }}-${{ github.workflow }}-${{
175
+ (github.event_name == 'pull_request' &&
176
+ github.event.number) || (github.event_name ==
177
+ ' workflow_dispatch' && github.run_number) || github.sha }}
157
178
run : echo "$CONCURRENCY_CONTEXT"
158
179
- name : Checkout
159
180
uses : actions/checkout@v4
160
181
with :
161
182
fetch-depth : 2
162
183
persist-credentials : true
163
- - name : Try to ensure the directories for core dumping exist and we
184
+ - name :
185
+ Try to ensure the directories for core dumping exist and we
164
186
can write them.
165
187
run : |
166
188
mkdir /tmp/cores || true
167
189
sysctl -w kernel.core_pattern=/tmp/cores/core.%u.%p.%t || true
168
190
- name : Checkout submodules & Bootstrap
169
191
uses : ./.github/actions/checkout-submodules-and-bootstrap
170
192
with :
171
- platform : linux
193
+ platform : linux
172
194
- name : Initialize CodeQL
173
195
if : ${{ inputs.run-codeql }}
174
196
uses : github/codeql-action/init@v3
@@ -188,6 +210,12 @@ jobs:
188
210
BUILD_TYPE=gcc_release scripts/tests/gn_tests.sh
189
211
- name : Clean output
190
212
run : rm -rf ./out
213
+
214
+ - name : Perform CodeQL Analysis
215
+ if : ${{ inputs.run-codeql }}
216
+ uses : ./.github/actions/perform-codeql-analysis
217
+ with :
218
+ language : cpp
191
219
- name : Run Tests with sanitizers
192
220
# Sanitizer tests are not likely to find extra issues so running the same tests
193
221
# as above repeatedly on every pull request seems extra time. Instead keep this run
@@ -223,7 +251,8 @@ jobs:
223
251
# NOTE: clang-tidy crashes on CodegenDataModel_Write due to Nullable/std::optional check.
224
252
# See https://github.com/llvm/llvm-project/issues/97426
225
253
env :
226
- ALL_CHANGED_FILES : ${{ steps.changed-files.outputs.all_changed_files }}
254
+ ALL_CHANGED_FILES :
255
+ ${{ steps.changed-files.outputs.all_changed_files }}
227
256
run : |
228
257
touch out/changed_files.txt
229
258
for file in ${ALL_CHANGED_FILES}; do
@@ -248,7 +277,9 @@ jobs:
248
277
--target linux-x64-rpc-console \
249
278
build \
250
279
"
251
- - name : Create a pre-generate directory and ensure compile-time codegen would fail
280
+ - name :
281
+ Create a pre-generate directory and ensure compile-time
282
+ codegen would fail
252
283
run : |
253
284
./scripts/run_in_build_env.sh "./scripts/codepregen.py ./zzz_pregenerated"
254
285
mv scripts/codegen.py scripts/codegen.py.renamed
@@ -264,7 +295,9 @@ jobs:
264
295
--pregen-dir ./zzz_pregenerated \
265
296
build \
266
297
"
267
- - name : Undo code pre-generation changes (make compile time codegen work again)
298
+ - name :
299
+ Undo code pre-generation changes (make compile time codegen
300
+ work again)
268
301
run : |
269
302
rm -rf ./zzz_pregenerated
270
303
mv scripts/codegen.py.renamed scripts/codegen.py
@@ -273,11 +306,6 @@ jobs:
273
306
run : |
274
307
./scripts/run_in_build_env.sh \
275
308
"./scripts/build/build_examples.py --target linux-fake-tests build"
276
- - name : Perform CodeQL Analysis
277
- if : ${{ inputs.run-codeql }}
278
- uses : ./.github/actions/perform-codeql-analysis
279
- with :
280
- language : cpp
281
309
282
310
- name : Uploading core files
283
311
uses : actions/upload-artifact@v4
@@ -312,7 +340,8 @@ jobs:
312
340
volumes :
313
341
- " /:/runner-root-volume"
314
342
- " /tmp/log_output:/tmp/test_logs"
315
- options : --sysctl "net.ipv6.conf.all.disable_ipv6=0
343
+ options :
344
+ --sysctl "net.ipv6.conf.all.disable_ipv6=0
316
345
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
317
346
318
347
steps :
@@ -322,14 +351,18 @@ jobs:
322
351
run : echo "$GITHUB_CONTEXT"
323
352
- name : Dump Concurrency context
324
353
env :
325
- CONCURRENCY_CONTEXT : ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
354
+ CONCURRENCY_CONTEXT :
355
+ ${{ github.ref }}-${{ github.workflow }}-${{
356
+ (github.event_name == 'pull_request' &&
357
+ github.event.number) || (github.event_name ==
358
+ ' workflow_dispatch' && github.run_number) || github.sha }}
326
359
run : echo "$CONCURRENCY_CONTEXT"
327
360
- name : Checkout
328
361
uses : actions/checkout@v4
329
362
- name : Checkout submodules & Bootstrap
330
363
uses : ./.github/actions/checkout-submodules-and-bootstrap
331
364
with :
332
- platform : linux
365
+ platform : linux
333
366
334
367
- name : Setup Build, Run Build and Run Tests
335
368
run : |
@@ -364,7 +397,9 @@ jobs:
364
397
python -m pip install -r scripts/setup/requirements.setuppayload.txt
365
398
python3 src/setup_payload/tests/run_python_setup_payload_test.py out/chip-tool
366
399
- name : Run revocation set generation tests
367
- run : scripts/run_in_build_env.sh 'python3 -m unittest -v credentials/generate_revocation_set.py'
400
+ run :
401
+ scripts/run_in_build_env.sh 'python3 -m unittest -v
402
+ credentials/generate_revocation_set.py'
368
403
369
404
build_linux_python_lighting_device :
370
405
name : Build on Linux (python lighting-app)
@@ -377,7 +412,8 @@ jobs:
377
412
volumes :
378
413
- " /:/runner-root-volume"
379
414
- " /tmp/log_output:/tmp/test_logs"
380
- options : --sysctl "net.ipv6.conf.all.disable_ipv6=0
415
+ options :
416
+ --sysctl "net.ipv6.conf.all.disable_ipv6=0
381
417
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
382
418
383
419
steps :
@@ -387,14 +423,18 @@ jobs:
387
423
run : echo "$GITHUB_CONTEXT"
388
424
- name : Dump Concurrency context
389
425
env :
390
- CONCURRENCY_CONTEXT : ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
426
+ CONCURRENCY_CONTEXT :
427
+ ${{ github.ref }}-${{ github.workflow }}-${{
428
+ (github.event_name == 'pull_request' &&
429
+ github.event.number) || (github.event_name ==
430
+ ' workflow_dispatch' && github.run_number) || github.sha }}
391
431
run : echo "$CONCURRENCY_CONTEXT"
392
432
- name : Checkout
393
433
uses : actions/checkout@v4
394
434
- name : Checkout submodules & Bootstrap
395
435
uses : ./.github/actions/checkout-submodules-and-bootstrap
396
436
with :
397
- platform : linux
437
+ platform : linux
398
438
399
439
- name : Setup Build
400
440
run : |
@@ -414,8 +454,10 @@ jobs:
414
454
- name : Checkout submodules & Bootstrap
415
455
uses : ./.github/actions/checkout-submodules-and-bootstrap
416
456
with :
417
- platform : darwin
418
- - name : Try to ensure the directory for diagnostic log collection exists
457
+ platform : darwin
458
+ - name :
459
+ Try to ensure the directory for diagnostic log collection
460
+ exists
419
461
run : |
420
462
mkdir -p ~/Library/Logs/DiagnosticReports || true
421
463
- name : Initialize CodeQL
@@ -454,7 +496,8 @@ jobs:
454
496
# NOTE: clang-tidy crashes on CodegenDataModel_Write due to Nullable/std::optional check.
455
497
# See https://github.com/llvm/llvm-project/issues/97426
456
498
env :
457
- ALL_CHANGED_FILES : ${{ steps.changed-files.outputs.all_changed_files }}
499
+ ALL_CHANGED_FILES :
500
+ ${{ steps.changed-files.outputs.all_changed_files }}
458
501
run : |
459
502
touch out/changed_files.txt
460
503
for file in ${ALL_CHANGED_FILES}; do
@@ -480,7 +523,7 @@ jobs:
480
523
if : ${{ inputs.run-codeql }}
481
524
uses : ./.github/actions/perform-codeql-analysis
482
525
with :
483
- language : cpp
526
+ language : cpp
484
527
485
528
# TODO Log Upload https://github.com/project-chip/connectedhomeip/issues/2227
486
529
# TODO https://github.com/project-chip/connectedhomeip/issues/1512
@@ -496,7 +539,8 @@ jobs:
496
539
volumes :
497
540
- " /:/runner-root-volume"
498
541
- " /tmp/log_output:/tmp/test_logs"
499
- options : --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
542
+ options :
543
+ --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
500
544
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
501
545
502
546
steps :
@@ -505,7 +549,7 @@ jobs:
505
549
- name : Checkout submodules & Bootstrap
506
550
uses : ./.github/actions/checkout-submodules-and-bootstrap
507
551
with :
508
- platform : linux
552
+ platform : linux
509
553
510
554
- name : Run Build Coverage
511
555
run : ./scripts/build_coverage.sh
0 commit comments