Skip to content

Commit 1de5de0

Browse files
Merge branch 'master' into fix/python-subscripiton
2 parents dcf35f1 + 9189b79 commit 1de5de0

File tree

119 files changed

+2532
-2201
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

119 files changed

+2532
-2201
lines changed

.github/actions/checkout-submodules-and-bootstrap/action.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ inputs:
1515
runs:
1616
using: "composite"
1717
steps:
18+
- name: Maximize runner disk
19+
uses: ./.github/actions/maximize-runner-disk
1820
- name: Dump disk info
1921
uses: ./.github/actions/dump-disk-info
2022
- name: Set git safe directory for local act runs
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Maximize runner disk
2+
description: Free up disk space on the github runner
3+
runs:
4+
using: "composite"
5+
steps:
6+
- name: Free up disk space on the github runner
7+
if: ${{ !env.ACT }}
8+
shell: bash
9+
run: |
10+
# maximize-runner-disk
11+
if [[ "$RUNNER_OS" == Linux ]]; then
12+
# Directories to prune to free up space. Candidates:
13+
# 1.6G /usr/share/dotnet
14+
# 1.1G /usr/local/lib/android/sdk/platforms
15+
# 1000M /usr/local/lib/android/sdk/build-tools
16+
# 8.9G /usr/local/lib/android/sdk
17+
# This list can be amended later to change the trade-off between the amount of
18+
# disk space freed up, and how long it takes to do so (deleting many files is slow).
19+
prune=(/usr/share/dotnet /usr/local/lib/android/sdk/platforms /usr/local/lib/android/sdk/build-tools)
20+
21+
if [[ "$UID" -eq 0 && -d /__w ]]; then
22+
root=/runner-root-volume
23+
if [[ ! -d "$root" ]]; then
24+
echo "Unable to maximize disk space, job is running inside a container and $root is not mounted"
25+
exit 0
26+
fi
27+
function sudo() { "$@"; } # we're already root (and sudo is probably unavailable)
28+
elif [[ "$UID" -ne 0 && "$RUNNER_ENVIRONMENT" == github-hosted ]]; then
29+
root=
30+
else
31+
echo "Unable to maximize disk space, unknown runner environment"
32+
exit 0
33+
fi
34+
35+
echo "Freeing up runner disk space on ${root:-/}"
36+
function avail() { df -k --output=avail "${root:-/}" | grep '^[0-9]*$'; }
37+
function now() { date '+%s'; }
38+
before="$(avail)" start="$(now)"
39+
for dir in "${prune[@]}"; do
40+
if [[ -d "${root}${dir}" ]]; then
41+
echo "- $dir"
42+
# du -sh -- "${root}${dir}"
43+
sudo rm -rf -- "${root}${dir}"
44+
else
45+
echo "- $dir (not found)"
46+
fi
47+
done
48+
after="$(avail)" end="$(now)"
49+
echo "Done, freed up $(( (after - before) / 1024 ))M of disk space in $(( end - start )) seconds."
50+
fi

.github/workflows/build.yaml

+5
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ jobs:
4242
container:
4343
image: ghcr.io/project-chip/chip-build:35
4444
volumes:
45+
- "/:/runner-root-volume"
4546
- "/tmp/log_output:/tmp/test_logs"
4647
options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
4748
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
@@ -137,6 +138,7 @@ jobs:
137138
container:
138139
image: ghcr.io/project-chip/chip-build:35
139140
volumes:
141+
- "/:/runner-root-volume"
140142
- "/tmp/log_output:/tmp/test_logs"
141143
options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
142144
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
@@ -285,6 +287,7 @@ jobs:
285287
container:
286288
image: ghcr.io/project-chip/chip-build:35
287289
volumes:
290+
- "/:/runner-root-volume"
288291
- "/tmp/log_output:/tmp/test_logs"
289292
options: --sysctl "net.ipv6.conf.all.disable_ipv6=0
290293
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
@@ -345,6 +348,7 @@ jobs:
345348
container:
346349
image: ghcr.io/project-chip/chip-build:35
347350
volumes:
351+
- "/:/runner-root-volume"
348352
- "/tmp/log_output:/tmp/test_logs"
349353
options: --sysctl "net.ipv6.conf.all.disable_ipv6=0
350354
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
@@ -453,6 +457,7 @@ jobs:
453457
container:
454458
image: ghcr.io/project-chip/chip-build:35
455459
volumes:
460+
- "/:/runner-root-volume"
456461
- "/tmp/log_output:/tmp/test_logs"
457462
options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0
458463
net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"

.github/workflows/darwin.yaml

+5-9
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,7 @@ jobs:
103103
# target versions instead?
104104
run: |
105105
mkdir -p /tmp/darwin/framework-tests
106-
echo "This is a simple log" > /tmp/darwin/framework-tests/end_user_support_log.txt
107-
../../../out/debug/chip-all-clusters-app --interface-id -1 --end_user_support_log /tmp/darwin/framework-tests/end_user_support_log.txt > >(tee /tmp/darwin/framework-tests/all-cluster-app.log) 2> >(tee /tmp/darwin/framework-tests/all-cluster-app-err.log >&2) &
106+
../../../out/debug/chip-all-clusters-app --interface-id -1 > >(tee /tmp/darwin/framework-tests/all-cluster-app.log) 2> >(tee /tmp/darwin/framework-tests/all-cluster-app-err.log >&2) &
108107
../../../out/debug/chip-all-clusters-app --interface-id -1 --dac_provider ../../../credentials/development/commissioner_dut/struct_cd_origin_pid_vid_correct/test_case_vector.json --product-id 32768 --discriminator 3839 --secured-device-port 5539 --KVS /tmp/chip-all-clusters-app-kvs2 > >(tee /tmp/darwin/framework-tests/all-cluster-app-origin-vid.log) 2> >(tee /tmp/darwin/framework-tests/all-cluster-app-origin-vid-err.log >&2) &
109108
# Disable BLE (CHIP_IS_BLE=NO) because the app does not have the permission to use it and that may crash the CI.
110109
@@ -120,13 +119,10 @@ jobs:
120119
run: |
121120
xcodebuild -target "MatterTvCastingBridge" -sdk iphoneos
122121
working-directory: examples/tv-casting-app/darwin/MatterTvCastingBridge
123-
- name: Uploading .ips files in Xcode derived data to debug the failure
124-
uses: actions/upload-artifact@v4
125-
if: ${{ failure() && !env.ACT }}
126-
with:
127-
name: darwin-framework-derived-data
128-
path: ~/Library/Developer/Xcode/DerivedData/**/*.ips
129-
retention-days: 5
122+
- name: Collect crash logs
123+
run: |
124+
mkdir -p /tmp/darwin/framework-tests
125+
find ~/Library/Developer/Xcode/DerivedData /Library/Logs/DiagnosticReports -name '*.ips' -print0 | xargs -0 -J % cp % /tmp/darwin/framework-tests
130126
- name: Uploading log files
131127
uses: actions/upload-artifact@v4
132128
if: ${{ failure() && !env.ACT }}

.github/workflows/java-tests.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -133,15 +133,15 @@ jobs:
133133
--tool-args "onnetwork-long-im-invoke --nodeid 1 --setup-pin-code 20202021 --discriminator 3840 -t 1000" \
134134
--factoryreset \
135135
'
136-
- name: Run IM Batch Invoke Test
136+
- name: Run IM Extendable Invoke Test
137137
run: |
138138
scripts/run_in_python_env.sh out/venv \
139139
'./scripts/tests/run_java_test.py \
140140
--app out/linux-x64-all-clusters-ipv6only-no-ble-no-wifi-tsan-clang-test/chip-all-clusters-app \
141141
--app-args "--discriminator 3840 --interface-id -1" \
142142
--tool-path out/linux-x64-java-matter-controller \
143143
--tool-cluster "im" \
144-
--tool-args "onnetwork-long-im-batch-invoke --nodeid 1 --setup-pin-code 20202021 --discriminator 3840 -t 1000" \
144+
--tool-args "onnetwork-long-im-extendable-invoke --nodeid 1 --setup-pin-code 20202021 --discriminator 3840 -t 1000" \
145145
--factoryreset \
146146
'
147147
- name: Run IM Read Test

.github/workflows/lint.yml

-2
Original file line numberDiff line numberDiff line change
@@ -123,12 +123,10 @@ jobs:
123123
--known-failure app/util/generic-callback-stubs.cpp \
124124
--known-failure app/util/im-client-callbacks.h \
125125
--known-failure app/util/MatterCallbacks.h \
126-
--known-failure app/util/message.cpp \
127126
--known-failure app/util/odd-sized-integers.h \
128127
--known-failure app/util/util.cpp \
129128
--known-failure app/util/util.h \
130129
--known-failure app/WriteHandler.h \
131-
--known-failure lib/core/CHIPVendorIdentifiers.hpp \
132130
--known-failure platform/DeviceSafeQueue.cpp \
133131
--known-failure platform/DeviceSafeQueue.h \
134132
--known-failure platform/GLibTypeDeleter.h \

.github/workflows/smoketest-android.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ jobs:
3939
container:
4040
image: ghcr.io/project-chip/chip-build-android:35
4141
volumes:
42+
- "/:/runner-root-volume"
4243
- "/tmp/log_output:/tmp/test_logs"
4344

4445
steps:

.github/workflows/unit_integration_test.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ jobs:
3939
container:
4040
image: ghcr.io/project-chip/chip-build:35
4141
volumes:
42+
- "/:/runner-root-volume"
4243
- "/tmp/log_output:/tmp/test_logs"
4344
options: --privileged --sysctl "net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1"
4445

build/chip/chip_codegen.gni

+4-4
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ template("_chip_build_time_codegen") {
3535
include_dirs = [ target_gen_dir ]
3636
}
3737

38-
pw_python_action("${_name}_codegen") {
38+
pw_python_action("${_name}_generate") {
3939
script = "${chip_root}/scripts/codegen.py"
4040

4141
# TODO: this seems to touch internals. Is this ok? speeds up builds!
@@ -99,7 +99,7 @@ template("_chip_build_time_codegen") {
9999
if (!defined(deps)) {
100100
deps = []
101101
}
102-
deps += [ ":${_name}_codegen" ]
102+
deps += [ ":${_name}_generate" ]
103103
}
104104
}
105105

@@ -152,7 +152,7 @@ template("_chip_build_time_zapgen") {
152152
_output_subdir = "zap-generated"
153153
}
154154

155-
pw_python_action("${_name}_zap") {
155+
pw_python_action("${_name}_generate") {
156156
script = "${chip_root}/scripts/tools/zap/generate.py"
157157

158158
# TODO: this seems to touch internals. Is this ok? speeds up builds!
@@ -211,7 +211,7 @@ template("_chip_build_time_zapgen") {
211211
if (!defined(public_deps)) {
212212
public_deps = []
213213
}
214-
public_deps += [ ":${_name}_zap" ]
214+
public_deps += [ ":${_name}_generate" ]
215215
}
216216
}
217217

build/config/BUILDCONFIG.gn

+4-7
Original file line numberDiff line numberDiff line change
@@ -76,11 +76,11 @@ if (_chip_defaults.custom_toolchain != "") {
7676
} else {
7777
_target_compiler = "gcc"
7878
}
79-
8079
_default_toolchain = "${_build_overrides.build_root}/toolchain/linux:linux_${target_cpu}_${_target_compiler}"
81-
} else if (target_os == host_os &&
82-
(target_cpu == host_cpu ||
83-
(target_cpu == "arm64e" && host_cpu == "arm64"))) {
80+
} else if (host_os == "mac" && (target_os == "mac" || target_os == "ios")) {
81+
# On Mac the host toolchain supports building for all mac and ios targets
82+
_default_toolchain = host_toolchain
83+
} else if (target_os == host_os && target_cpu == host_cpu) {
8484
_default_toolchain = host_toolchain
8585
} else if (target_os == "freertos") {
8686
if (_chip_defaults.is_clang) {
@@ -113,9 +113,6 @@ if (_chip_defaults.custom_toolchain != "") {
113113
} else {
114114
assert(false, "Unsupported target_cpu: ${current_cpu}")
115115
}
116-
} else if (target_os == "ios") {
117-
_default_toolchain =
118-
"${_build_overrides.build_root}/toolchain/ios:ios_${target_cpu}"
119116
} else if (target_os == "tizen") {
120117
_default_toolchain =
121118
"${_build_overrides.build_root}/toolchain/tizen:tizen_${target_cpu}"

build/config/compiler/BUILD.gn

+2-2
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ config("cosmetic_default") {
343343
}
344344

345345
config("runtime_default") {
346-
if (is_clang) {
346+
if (is_clang) { # Using Pigweed clang instead of Darwin host clang
347347
configs = [
348348
"$dir_pw_toolchain/host_clang:no_system_libcpp",
349349
"$dir_pw_toolchain/host_clang:xcode_sysroot",
@@ -402,7 +402,7 @@ config("sanitize_address") {
402402
]
403403
ldflags = cflags
404404

405-
if (target_os == "mac" || target_os == "ios") {
405+
if ((target_os == "mac" || target_os == "ios") && !is_clang) {
406406
defines += [ "_LIBCPP_HAS_NO_ASAN" ]
407407
}
408408
}

build/toolchain/ios/BUILD.gn

-42
This file was deleted.
Loading

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

+2-2
Original file line numberDiff line numberDiff line change
@@ -7761,7 +7761,7 @@ endpoint 1 {
77617761
callback attribute eventList;
77627762
callback attribute attributeList;
77637763
ram attribute featureMap default = 0x0001;
7764-
ram attribute clusterRevision default = 5;
7764+
ram attribute clusterRevision default = 6;
77657765

77667766
handle command Off;
77677767
handle command On;
@@ -9134,7 +9134,7 @@ endpoint 2 {
91349134
callback attribute eventList;
91359135
callback attribute attributeList;
91369136
ram attribute featureMap default = 0x0001;
9137-
ram attribute clusterRevision default = 5;
9137+
ram attribute clusterRevision default = 6;
91389138

91399139
handle command Off;
91409140
handle command On;

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

+3-3
Original file line numberDiff line numberDiff line change
@@ -6659,7 +6659,7 @@
66596659
"storageOption": "RAM",
66606660
"singleton": 0,
66616661
"bounded": 0,
6662-
"defaultValue": "5",
6662+
"defaultValue": "6",
66636663
"reportable": 1,
66646664
"minInterval": 0,
66656665
"maxInterval": 65344,
@@ -6895,7 +6895,7 @@
68956895
"storageOption": "RAM",
68966896
"singleton": 0,
68976897
"bounded": 0,
6898-
"defaultValue": "5",
6898+
"defaultValue": "6",
68996899
"reportable": 1,
69006900
"minInterval": 0,
69016901
"maxInterval": 65344,
@@ -23993,7 +23993,7 @@
2399323993
"storageOption": "RAM",
2399423994
"singleton": 0,
2399523995
"bounded": 0,
23996-
"defaultValue": "5",
23996+
"defaultValue": "6",
2399723997
"reportable": 1,
2399823998
"minInterval": 0,
2399923999
"maxInterval": 65344,

0 commit comments

Comments
 (0)