Skip to content

Commit 2567f80

Browse files
authored
Merge branch 'master' into remove-interation
2 parents e78c013 + 0a765c6 commit 2567f80

File tree

9 files changed

+84
-68
lines changed

9 files changed

+84
-68
lines changed

.github/workflows/examples-linux-standalone.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ jobs:
115115
linux debug all-clusters-app \
116116
out/linux-x64-all-clusters/chip-all-clusters-app \
117117
/tmp/bloat_reports/
118-
- name: Build example Standalone All Clusters Mininal Server
118+
- name: Build example Standalone All Clusters Minimal Server
119119
timeout-minutes: 10
120120
run: |
121121
./scripts/run_in_build_env.sh \
@@ -124,7 +124,7 @@ jobs:
124124
build"
125125
.environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
126126
linux debug all-clusters-minimal-app \
127-
out/linux-x64-all-clusters-minimal/chip-all-clusters-app \
127+
out/linux-x64-all-clusters-minimal/chip-all-clusters-minimal-app \
128128
/tmp/bloat_reports/
129129
- name: Build example TV app
130130
timeout-minutes: 10

examples/all-clusters-app/all-clusters-common/all-clusters-app.zap

+14-13
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"featureLevel": 81,
2+
"featureLevel": 87,
33
"creator": "zap",
44
"keyValuePairs": [
55
{
@@ -16,19 +16,19 @@
1616
}
1717
],
1818
"package": [
19-
{
20-
"pathRelativity": "relativeToZap",
21-
"path": "../../../src/app/zap-templates/app-templates.json",
22-
"type": "gen-templates-json",
23-
"version": "chip-v1"
24-
},
2519
{
2620
"pathRelativity": "relativeToZap",
2721
"path": "../../../src/app/zap-templates/zcl/zcl-with-test-extensions.json",
2822
"type": "zcl-properties",
2923
"category": "matter",
3024
"version": 1,
3125
"description": "Matter SDK ZCL data with some extensions"
26+
},
27+
{
28+
"pathRelativity": "relativeToZap",
29+
"path": "../../../src/app/zap-templates/app-templates.json",
30+
"type": "gen-templates-json",
31+
"version": "chip-v1"
3232
}
3333
],
3434
"endpointTypes": [
@@ -8058,7 +8058,7 @@
80588058
"name": "Unit Testing",
80598059
"code": 4294048773,
80608060
"mfgCode": null,
8061-
"define": "TEST_CLUSTER",
8061+
"define": "UNIT_TESTING_CLUSTER",
80628062
"side": "client",
80638063
"enabled": 0,
80648064
"commands": [
@@ -8110,7 +8110,7 @@
81108110
"name": "Unit Testing",
81118111
"code": 4294048773,
81128112
"mfgCode": null,
8113-
"define": "TEST_CLUSTER",
8113+
"define": "UNIT_TESTING_CLUSTER",
81148114
"side": "server",
81158115
"enabled": 0,
81168116
"commands": [
@@ -9709,7 +9709,7 @@
97099709
"code": 15,
97109710
"mfgCode": null,
97119711
"side": "server",
9712-
"type": "bitmap8",
9712+
"type": "LevelControlOptions",
97139713
"included": 1,
97149714
"storageOption": "RAM",
97159715
"singleton": 0,
@@ -19162,7 +19162,7 @@
1916219162
"name": "Unit Testing",
1916319163
"code": 4294048773,
1916419164
"mfgCode": null,
19165-
"define": "TEST_CLUSTER",
19165+
"define": "UNIT_TESTING_CLUSTER",
1916619166
"side": "client",
1916719167
"enabled": 0,
1916819168
"commands": [
@@ -19334,7 +19334,7 @@
1933419334
"name": "Unit Testing",
1933519335
"code": 4294048773,
1933619336
"mfgCode": null,
19337-
"define": "TEST_CLUSTER",
19337+
"define": "UNIT_TESTING_CLUSTER",
1933819338
"side": "server",
1933919339
"enabled": 1,
1934019340
"commands": [
@@ -24740,5 +24740,6 @@
2474024740
"endpointVersion": 1,
2474124741
"deviceIdentifier": 61442
2474224742
}
24743-
]
24743+
],
24744+
"log": []
2474424745
}

examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap

+14-13
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"featureLevel": 81,
2+
"featureLevel": 87,
33
"creator": "zap",
44
"keyValuePairs": [
55
{
@@ -16,19 +16,19 @@
1616
}
1717
],
1818
"package": [
19+
{
20+
"pathRelativity": "relativeToZap",
21+
"path": "../../../src/app/zap-templates/app-templates.json",
22+
"type": "gen-templates-json",
23+
"version": "chip-v1"
24+
},
1925
{
2026
"pathRelativity": "relativeToZap",
2127
"path": "../../../src/app/zap-templates/zcl/zcl.json",
2228
"type": "zcl-properties",
2329
"category": "matter",
2430
"version": 1,
2531
"description": "Matter SDK ZCL data"
26-
},
27-
{
28-
"pathRelativity": "relativeToZap",
29-
"path": "../../../src/app/zap-templates/app-templates.json",
30-
"type": "gen-templates-json",
31-
"version": "chip-v1"
3232
}
3333
],
3434
"endpointTypes": [
@@ -8058,7 +8058,7 @@
80588058
"name": "Unit Testing",
80598059
"code": 4294048773,
80608060
"mfgCode": null,
8061-
"define": "TEST_CLUSTER",
8061+
"define": "UNIT_TESTING_CLUSTER",
80628062
"side": "client",
80638063
"enabled": 0,
80648064
"commands": [
@@ -8110,7 +8110,7 @@
81108110
"name": "Unit Testing",
81118111
"code": 4294048773,
81128112
"mfgCode": null,
8113-
"define": "TEST_CLUSTER",
8113+
"define": "UNIT_TESTING_CLUSTER",
81148114
"side": "server",
81158115
"enabled": 0,
81168116
"commands": [
@@ -9559,7 +9559,7 @@
95599559
"code": 15,
95609560
"mfgCode": null,
95619561
"side": "server",
9562-
"type": "bitmap8",
9562+
"type": "LevelControlOptions",
95639563
"included": 1,
95649564
"storageOption": "RAM",
95659565
"singleton": 0,
@@ -18954,7 +18954,7 @@
1895418954
"name": "Unit Testing",
1895518955
"code": 4294048773,
1895618956
"mfgCode": null,
18957-
"define": "TEST_CLUSTER",
18957+
"define": "UNIT_TESTING_CLUSTER",
1895818958
"side": "client",
1895918959
"enabled": 0,
1896018960
"commands": [
@@ -19126,7 +19126,7 @@
1912619126
"name": "Unit Testing",
1912719127
"code": 4294048773,
1912819128
"mfgCode": null,
19129-
"define": "TEST_CLUSTER",
19129+
"define": "UNIT_TESTING_CLUSTER",
1913019130
"side": "server",
1913119131
"enabled": 1,
1913219132
"commands": [
@@ -24516,5 +24516,6 @@
2451624516
"endpointVersion": 1,
2451724517
"deviceIdentifier": 61442
2451824518
}
24519-
]
24519+
],
24520+
"log": []
2452024521
}

examples/thermostat/thermostat-common/thermostat.zap

+12-12
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"featureLevel": 85,
2+
"featureLevel": 87,
33
"creator": "zap",
44
"keyValuePairs": [
55
{
@@ -16,19 +16,19 @@
1616
}
1717
],
1818
"package": [
19+
{
20+
"pathRelativity": "relativeToZap",
21+
"path": "../../../src/app/zap-templates/app-templates.json",
22+
"type": "gen-templates-json",
23+
"version": "chip-v1"
24+
},
1925
{
2026
"pathRelativity": "relativeToZap",
2127
"path": "../../../src/app/zap-templates/zcl/zcl.json",
2228
"type": "zcl-properties",
2329
"category": "matter",
2430
"version": 1,
2531
"description": "Matter SDK ZCL data"
26-
},
27-
{
28-
"pathRelativity": "relativeToZap",
29-
"path": "../../../src/app/zap-templates/app-templates.json",
30-
"type": "gen-templates-json",
31-
"version": "chip-v1"
3232
}
3333
],
3434
"endpointTypes": [
@@ -7014,7 +7014,7 @@
70147014
"name": "Unit Testing",
70157015
"code": 4294048773,
70167016
"mfgCode": null,
7017-
"define": "TEST_CLUSTER",
7017+
"define": "UNIT_TESTING_CLUSTER",
70187018
"side": "client",
70197019
"enabled": 0,
70207020
"commands": [
@@ -7066,7 +7066,7 @@
70667066
"name": "Unit Testing",
70677067
"code": 4294048773,
70687068
"mfgCode": null,
7069-
"define": "TEST_CLUSTER",
7069+
"define": "UNIT_TESTING_CLUSTER",
70707070
"side": "server",
70717071
"enabled": 0,
70727072
"commands": [
@@ -8335,7 +8335,7 @@
83358335
"code": 15,
83368336
"mfgCode": null,
83378337
"side": "server",
8338-
"type": "bitmap8",
8338+
"type": "LevelControlOptions",
83398339
"included": 1,
83408340
"storageOption": "RAM",
83418341
"singleton": 0,
@@ -14132,7 +14132,7 @@
1413214132
"name": "Unit Testing",
1413314133
"code": 4294048773,
1413414134
"mfgCode": null,
14135-
"define": "TEST_CLUSTER",
14135+
"define": "UNIT_TESTING_CLUSTER",
1413614136
"side": "client",
1413714137
"enabled": 0,
1413814138
"commands": [
@@ -14176,7 +14176,7 @@
1417614176
"name": "Unit Testing",
1417714177
"code": 4294048773,
1417814178
"mfgCode": null,
14179-
"define": "TEST_CLUSTER",
14179+
"define": "UNIT_TESTING_CLUSTER",
1418014180
"side": "server",
1418114181
"enabled": 0,
1418214182
"commands": [

examples/tv-app/tv-common/tv-app.zap

+14-13
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"featureLevel": 81,
2+
"featureLevel": 87,
33
"creator": "zap",
44
"keyValuePairs": [
55
{
@@ -16,19 +16,19 @@
1616
}
1717
],
1818
"package": [
19+
{
20+
"pathRelativity": "relativeToZap",
21+
"path": "../../../src/app/zap-templates/app-templates.json",
22+
"type": "gen-templates-json",
23+
"version": "chip-v1"
24+
},
1925
{
2026
"pathRelativity": "relativeToZap",
2127
"path": "../../../src/app/zap-templates/zcl/zcl.json",
2228
"type": "zcl-properties",
2329
"category": "matter",
2430
"version": 1,
2531
"description": "Matter SDK ZCL data"
26-
},
27-
{
28-
"pathRelativity": "relativeToZap",
29-
"path": "../../../src/app/zap-templates/app-templates.json",
30-
"type": "gen-templates-json",
31-
"version": "chip-v1"
3232
}
3333
],
3434
"endpointTypes": [
@@ -6924,7 +6924,7 @@
69246924
"name": "Unit Testing",
69256925
"code": 4294048773,
69266926
"mfgCode": null,
6927-
"define": "TEST_CLUSTER",
6927+
"define": "UNIT_TESTING_CLUSTER",
69286928
"side": "client",
69296929
"enabled": 0,
69306930
"commands": [
@@ -6976,7 +6976,7 @@
69766976
"name": "Unit Testing",
69776977
"code": 4294048773,
69786978
"mfgCode": null,
6979-
"define": "TEST_CLUSTER",
6979+
"define": "UNIT_TESTING_CLUSTER",
69806980
"side": "server",
69816981
"enabled": 0,
69826982
"commands": [
@@ -9222,7 +9222,7 @@
92229222
"name": "Unit Testing",
92239223
"code": 4294048773,
92249224
"mfgCode": null,
9225-
"define": "TEST_CLUSTER",
9225+
"define": "UNIT_TESTING_CLUSTER",
92269226
"side": "client",
92279227
"enabled": 0,
92289228
"commands": [
@@ -9274,7 +9274,7 @@
92749274
"name": "Unit Testing",
92759275
"code": 4294048773,
92769276
"mfgCode": null,
9277-
"define": "TEST_CLUSTER",
9277+
"define": "UNIT_TESTING_CLUSTER",
92789278
"side": "server",
92799279
"enabled": 0,
92809280
"commands": [
@@ -9977,7 +9977,7 @@
99779977
"code": 15,
99789978
"mfgCode": null,
99799979
"side": "server",
9980-
"type": "bitmap8",
9980+
"type": "LevelControlOptions",
99819981
"included": 1,
99829982
"storageOption": "RAM",
99839983
"singleton": 0,
@@ -12364,5 +12364,6 @@
1236412364
"endpointVersion": 1,
1236512365
"deviceIdentifier": 36
1236612366
}
12367-
]
12367+
],
12368+
"log": []
1236812369
}

scripts/tools/zap/generate.py

+13-1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
import json
2020
import os
2121
from pathlib import Path
22+
import tempfile
2223
import subprocess
2324
import sys
2425
import urllib.request
@@ -268,7 +269,18 @@ def main():
268269
# Parallel-compatible runs will need separate state
269270
os.environ["ZAP_TEMPSTATE"] = "1"
270271

271-
runGeneration(cmdLineArgs.zapFile, cmdLineArgs.zclFile, cmdLineArgs.templateFile, cmdLineArgs.outputDir)
272+
# `zap-cli` may extract things into a temporary directory. ensure extraction
273+
# does not conflict.
274+
with tempfile.TemporaryDirectory(prefix='zap') as temp_dir:
275+
old_temp = os.environ['TEMP'] if 'TEMP' in os.environ else None
276+
os.environ['TEMP'] = temp_dir
277+
278+
runGeneration(cmdLineArgs.zapFile, cmdLineArgs.zclFile, cmdLineArgs.templateFile, cmdLineArgs.outputDir)
279+
280+
if old_temp:
281+
os.environ['TEMP'] = old_temp
282+
else:
283+
del os.environ['TEMP']
272284

273285
prettifiers = [
274286
runClangPrettifier,

0 commit comments

Comments
 (0)