Skip to content

Sync csa branch with main - #1193

Merged
sarthak shaha (Sarthak-Shaha) merged 16 commits into
mainfrom
automation/update_main
Sep 16, 2026
Merged

sarthak shaha (Sarthak-Shaha) merged 16 commits into
mainfrom
automation/update_main

Conversation

@silabs-matter-ci-bot

Copy link
Copy Markdown
Contributor

This PR syncs the csa branch with the main branch.

PR MUST BE MERGED WITH MERGE COMMIT - ADMIN MUST ENABLE THE OPTION

…21 (#74096)

* TC-AVANALY: Update TC-AVANALY-2.5, 2.6, and 2.7 for test plan PR #6421

* TC_AVANALY_2_5.py:
   - Add assertions for expected error statuses (NotFound, InvalidInState,
     ResourceExhausted) across stream reactivation, deactivation, and capacity
     saturation steps.
   - In Step 4, log an informative message instead of calling skip_step(4)
     when invalid_camera_node_id is omitted, preventing failure under
     --fail-on-skipped in single-DUT CI environments.

* TC_AVANALY_2_6.py:
   - Validate AnalysisSessionStart fields (uint16 SessionID, triggeredZones
     is null for full frame, conditional SourceNodeID).
   - Validate AnalysisSessionEnd matching SessionID and SourceNodeID.
   - Add Step 7 to disable context triggers via DisableContextTriggers.

* TC_AVANALY_2_7.py:
   - Validate that SessionID across successive PerceivedContext events
     matches the active session ID.
   - Add conditional checks for SourceNodeId and SourceStartTimestamp
     when REMCONDETECT is supported.
   - Add Step 9 to cleanly end the session and disable context triggers.

* [TC-AVANALY] Address PR review feedback for TC-AVANALY-2.5, 2.6, and 2.7

- TC_AVANALY_2_5.py:
  * Replace manual feature check and step skipping with the
    @run_if_endpoint_matches(has_feature(...)) decorator on test_TC_AVANALY_2_5.
  * Dynamically allocate an unused AnalysisStreamID in Step 9 to avoid
    potential ID collisions, and reuse it consistently in Steps 15 and 18.
  * Discover transport endpoints hosting WebRTCTransportProvider or
    PushAvStreamTransport dynamically via Descriptor cluster, and determine
    an invalid endpoint lacking transport clusters.
  * Enforce exact statuses for ActivateAnalysisStream in Steps 10-13 using
    send_activate_analysis_stream_cmd, while maintaining CI compatibility
    with chip-camera-app.

- Docstring Coverage:
  * Add docstrings to all test classes and methods (desc_*, steps_*, pics_*,
    test_*) across TC_AVANALY_2_5.py, TC_AVANALY_2_6.py, TC_AVANALY_2_7.py,
    and TC_AVANALYTestBase.py to satisfy CI coverage requirements.

* [TC-AVANALY-2.5] Select single transport type for stream activation

When both WebRTC and PushAV transports are discovered on the device,
select exactly one transport for stream activation and validate the
corresponding stream state and endpoint ID, addressing CodeRabbit review
feedback on PR #74096.
* Docker: isolate private OpenSSL installation and expose linkage selection

Install OpenSSL 3.5 under /opt/matter/openssl while preserving system
library discovery for unrelated tools. Add the OPENSSL_STATIC build
argument and certification-image workflow input.

CHIP_OPENSSL_ROOT and CHIP_OPENSSL_STATIC require the SDK configuration
changes in the follow-up commit. Older SDK revisions ignore these
variables and continue to use their existing OpenSSL discovery.

* Docker: verify prebuilt OpenSSL libraries for CI reuse

* Docker: defer certification-image workflow changes to SDK branch

* Docker: bump shared image version to 212 for private OpenSSL

* Build: include private OpenSSL selection and static target option with Docker images

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Docker: move SDK build changes and documentation to dependent branch

* fixed version number

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* TC-SC-5.1: Disable in CI

This is blocking the roll to 1.7 and delaying the release of the
test harness. This is jeopardizing the test event.

Groupcast team will need to re-enable before SVE
project-chip/connectedhomeip#74154

* Revert SC changes, just keep test_metadata

* Restyled by whitespace

---------

Co-authored-by: Andrei Litvin <andy314@gmail.com>
Co-authored-by: Restyled.io <commits@restyled.io>
* Commit 1.6.1 DM files in 1.7 directory to serve as a base for review

* Introduce 1.7 Data Model files

* Update spec tests and revision reference

* Update cluster and device revisions in zap and tests

* Update out-of-sync zap xmls

* Fix device-energy-management-mode-cluster

* Regen with clean Alchemy

* Fix Groups unittest

* Add 1.7 to binfo_attributes_verification

* Add obsolete conformance support for idm testing

* Fix IDM test

* Remove unused import

* Update IDM_9_1 to support obsolete

* Level Control constraint fix

* Zap Regen

* Regen Zap

* Update ZAP XML + Regen

* Support numeric constraints

* Fix lint

* Fix Scene test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix lint

* Revert audio control changes

* Complete support for obsolete conform

* Update push-av-stream and zap regen

* Fix av stream

* Zap regen

* Fix groupcast test

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix Groups tests

* zap regen

* Fix Thermostat renames

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Test fixes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix SC_5_1

* Fix tests

* Address lint

* Disable TC_SC_5_1

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Andrei Litvin <andy314@gmail.com>
…-merged by bot)

Bumps [third_party/simw-top-mini/repo](https://github.com/NXP/plug-and-trust) from `87b78ff` to `f82e093`.
- [Release notes](https://github.com/NXP/plug-and-trust/releases)
- [Commits](NXP/plug-and-trust@87b78ff...f82e093)

---
updated-dependencies:
- dependency-name: third_party/simw-top-mini/repo
  dependency-version: f82e09343fe09765a62854770cc2033001b16b06
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…(#74130)

* [OTA Provider Example] Bind BDX transfer to the QueryImage requester

The example OTA provider records the fabric index and node id of the
requester that issued QueryImage in InitializeTransfer(), but does not
verify that the peer initiating the subsequent BDX transfer is that same
requester before accepting it.

Override BdxOtaSender::OnMessageReceived to compare the initiating
session's fabric index and node id against the stored values, rejecting a
mismatch with CHIP_ERROR_INVALID_DESTINATION_NODE_ID. The check runs only
for an exchange other than the one already driving the transfer, so it
does not disturb the active exchange's message flow.

Add TestBdxOtaSenderPeerBinding covering the accepted requester, a
different node id, and the same node id on a different fabric.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* [OTA Provider Example] Simplify BDX requester check and widen session gate

Address review feedback on the peer-binding check:

- Run the fabric/node comparison unconditionally instead of guarding it with
  `ec != mExchangeCtx`. The exchange already driving the transfer matches the
  armed requester by construction, so it always passes and is never rejected;
  the guard was redundant and relied on raw-pointer identity.
- Gate on a secure session to reject group and unauthenticated sessions, whose
  reported peer is the unauthenticated packet-header source rather than an
  authenticated identity. Correct the comment to state this reason.
- Mark the override final.

* [OTA Provider Example] Test that the driving exchange's later messages are not rejected

Add a regression test that delivers a second message on the exchange already
driving the transfer and checks the override delegates to the base rather than
returning early. An early return there would skip the base's WillSendMessage()
and free the exchange the transfer still holds; this pins that the peer check,
which now runs unconditionally, never rejects the driving exchange.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* [TEST ONLY] [workflows] Enable nightly slow-test workflow on PRs

Uncomment the TEST SECTION triggers in nightly.yaml (push to
master/v*-branch, pull_request, merge_group) so the slow
Software Update (TC_SU) tests and the rest of the nightly matrix
run on pull requests instead of only on the daily schedule.

The matrix filters ("", TC_SU_2_2, TC_SU_2_4, TC_SU_2_5, TC_SU_2_7,
"!TC_SU") cover every entry of the nightly section in
src/python_testing/test_metadata.yaml, so no nightly test is dropped:
the four TC_SU tests run individually and "!TC_SU" picks up
TC_CC_2_2 and TC_BRBINFO_4_1.

This is a temporary CI toggle and is reverted in the following commit.

* Revert "[TEST ONLY] [workflows] Enable nightly slow-test workflow on PRs"

This reverts commit dcb63c5719dcb796933324ebdee6345bf8e7326d.

* [OTA Provider Example] Assert the base handler's response on the driving exchange

The driving-exchange test delivered a second ReceiveInit without draining the
pending output the first one produced, so TransferSession rejected it at the
pending-output check before its state machine saw it. The test only asserted
the return value was not the peer-mismatch code, which any early return with a
different code would have satisfied.

Poll the sender twice to accept the transfer and send the ReceiveAccept, then
deliver the second init: the transfer session now answers it with an
unexpected-message status report and returns success, so EXPECT_SUCCESS rejects
every early-return code. Verified by reintroducing an early return on the
driving exchange, which turns this test red and leaves the other three green.

Also drop the claim that ASan flags the exchange free at teardown. The test
calls OnMessageReceived directly, so ExchangeContext::MessageHandled() never
runs and nothing frees the exchange.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
…111)

* Ambient Context Sensing Cluster Test Script PR

Recreate a new PR as a continuation of  PR43197 (project-chip/connectedhomeip#43197) to resolve the rebase problem.
Test script files are same as PR43197.

* Moving TC_ACS_xx test script files.

* Updated TC_ACS_2_1, 3_1, 3_3 test script files according to coderabbitai recommendations.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update TC_ACS_2_1.py

* Update TC_ACS_2_1.py

* Update TC_ACS_2_1.py

* Update TC_ACS_3_3.py

* Update TC_ACS_3_3.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
… (#74019)

* Add persistent attributes migration code to camera-av-settings-user-level-management cluster

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Code update

* Update attribute_persistence_provider_exclusions.txt

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix unit tests

* Address review comments

* Update comment

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
…es (#73747)

* Update secure session peer address only after the message authenticates

SecureUnicastMessageDispatch finds a session from the session id in the
message header and then updates that session's cached peer address, which
happens before SecureMessageCodec::Decrypt and the message counter check.
A message that never authenticates therefore still changes where the
session sends its subsequent messages.

Move the peer address update below the decryption and counter checks, next
to MarkActiveRx(), which is where it sat before a8cfbac. Decrypt does
not read the cached peer address, so nothing in the function needs the
earlier update.

The same pattern applies to the SetTCPConnection association a few lines
below and to the unauthenticated session path; both are left unchanged
here.

* Do not update the peer address from a replayed message

VerifyEncryptedUnicast reports a message whose counter was already seen as
CHIP_ERROR_DUPLICATE_MESSAGE_RECEIVED, which the dispatch converts to
success so the duplicate can still be acked. The peer address update sat
above that handling, so resending a copy of an already accepted message
from a different source address still updated the cached address.

Move the update into the non-duplicate branch, after
CommitEncryptedUnicast. A peer that changes address is still tracked,
because the first message it sends from the new address carries a fresh
message counter.

Add tests for both directions: a replay from a different address leaves
the cached address unchanged, and an accepted message from a new address
updates it.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Return CHIP_ERROR from the peer address test helpers

ASSERT_* in a void helper returns from the helper only, so a failure in
InjectSessionPair or PrepareTestMessage left the calling test running with
an unset EncryptedPacketBufferHandle, which CastToWritable then
dereferences. The static analyzer reports this as a null dereference in
PacketBufferHandle::Retain.

Have both helpers return CHIP_ERROR and check them with ASSERT_SUCCESS at
the call sites, so a setup failure stops the test, and assert the prepared
message is non-null before it is used.

Also rename TestUnauthenticMessageDoesNotRebindPeerAddress to
TestUndecryptableMessageDoesNotRebindPeerAddress and narrow its comment to
the peer address, which is what it asserts.

* Make the replay test exercise the non-duplicate guard

The replayed message did not set NeedsAck, so it returned at the
duplicate-without-ack fast path and never reached the peer address update
that the test is meant to cover. A placement that updated the address after
that early return, without the isDuplicate == No guard, passed the test
regardless.

Set NeedsAck on the prepared message so the replayed duplicate falls
through to the guard, and assert the cloned buffers are non-null before
they are dispatched.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* clarify comment

* Explain why the peer address only updates on a new message

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
* New Ambient Sensing Union Cluster test script

Three Python test scripts files for Ambient Sensing Union Cluster are available for review.
This test script reflects the test plan PR5129 (CHIP-Specifications/chip-test-plans#5129)

* Delete src/python_testing/TC_ASU_2_1.py

* Delete src/python_testing/TC_ASU_2_2.py

* Delete src/python_testing/TC_ASU_3_1.py

* Ambient Sensing Union Test Script Addition

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update TC_ASU_2_1.py

Added a string size check (1 to 128)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update TC_ASU_2_1.py

* Update TC_ASU_2_1.py

* Update TC_ASU_2_2.py

Updated from coderabbitai recommendation

* Apply suggestion from @OliverFan1

Co-authored-by: Oliver FAN <156269022+OliverFan1@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update TC_ASU_2_2.py

* Update TC_ASU_3_1.py

* Apply suggestion from @OliverFan1

Co-authored-by: Oliver FAN <156269022+OliverFan1@users.noreply.github.com>

* Update TC_ASU_2_1.py

Removed TestStep objects.

* Update TC_ASU_2_2.py

Removed TestStep objects.

* Update TC_ASU_3_1.py

Removed TestStep objects

* Update TC_ASU_2_1.py

* Update TC_ASU_2_1.py

* Moved TC_ASU test scripts

* Update TC_ASU_3_1.py

* Update TC_ASU_3_1.py

temporary bypass step 6

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update TC_ASU_3_1.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add files via upload

Updating TC_ASU_2_2.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Oliver FAN <156269022+OliverFan1@users.noreply.github.com>
…t triggers for RemoteContextDetection (#73986)

* [AVAnalysis] Handle EnableContextTriggers for RemoteContextDetection

* [AVAnalysis] Validate all EnableContextTriggers entries before applying any

* [AVAnalysis] Report the source camera in events under RemoteContextDetection

* [AVAnalysis] Add the WebRTC client for RemoteContextDetection

AvAnalysisWebRTCClient is the interface the cluster will drive to
initiate and end the WebRTC sessions carrying analysis streams; the.
Startup now requires a RemoteContextDetection instance to have its
camera client wired, so a misconfigured node fails at registration
instead of at first use.

* [AVAnalysis] Track the WebRTC session id and the activation interaction states

* [AVAnalysis] Require the WebRTC client at Startup with Remote Detection

* [AVAnalysis] Initiate WebRTC sessions from ActivateAnalysisStream

* [AVAnalysis] End WebRTC sessions from DeactivateAnalysisStream

* [AVAnalysis] Mark the stream Failure when its WebRTC session fails

* [AVAnalysis] Add the default WebRTC client with the provider-presence check

* [AVAnalysis] Send ProvideOffer and register the assigned WebRTC session

* [AVAnalysis] End WebRTC sessions with EndSession

* [AVAnalysis] Route inbound WebRTC session signals to the cluster

NotifyAnswered reaches the initiating callback as OnSessionActive.
NotifyFailed and NotifyEnded release the session (requestor record,
peer connection, tracking slot) and report OnSessionFailed: to the AV
Analysis cluster, an End this node did not request is a failure.

The peer delegate gains OnOfferAbandoned so the application can drop
the peer connection of an offer that never became a session.
Cancel now also forgets every tracked session, for shutdown.

* [AVAnalysis] Forget a WebRTC session once its EndSession has completed

   A stream whose EndSession failed goes to Failure, whose only exit is a
   new session, so nothing could ever end the old one again: keeping it
   tracked leaked a slot, a requestor record and a peer connection per
   failed Deactivate. The client now releases the session on every
   EndSession completion and the logic drops the entry's session id.

* [AVAnalysis] Send this node's ICE candidates with ProvideICECandidates

The trickle phase of the WebRTC Normal Flow: the application hands
the default client its gathered candidates for a tracked session and
the client sends them to that session's camera as one batch. Single
flight like the other requests, so the application sends once the
camera's Answer has arrived; the outcome is logged only, a camera
left without them fails the connection through the media layer.

* [AVAnalysis] Mark a WebRTC session active when its connection is established

The spec sets WebRTCActive on completion of the signaling flow, whose
last phase is the media connection; the Answer only ends the first.
NotifyAnswered becomes NotifyConnected, for the application to call
when the session's peer connection reaches Connected.

* [AVAnalysis] Sort the WebRTC client header in the build listings

* [AVAnalysis] Mark the stream PendingDeactivation before sending EndSession

* [AVAnalysis] Mark the stream PendingDeactivation before sending EndSession

* [AVAnalysis] Deliver every WebRTC command outcome from OnDone

* [AVAnalysis] Assign the peer session after the offer request completes

* [AVAnalysis] Refuse a session request with no free tracking slot

* [AVAnalysis] Fail the provider check when the ServerList cannot be read

* [AVAnalysis] Key WebRTC sessions by camera and session id

Session ids are assigned by each camera and unique only within it, so
two cameras hand out the same id and a signal for one camera's session
could land on the other's stream. The client's tracked sessions and the
logic's stream lookup now match the camera together with the id, as the
WebRTC Transport Requestor cluster already does; the inbound Notify
methods, SendICECandidates, the session callbacks and the peer
delegate carry the camera accordingly.

* [AVAnalysis] Read optionals in the tests the way clang-tidy accepts

* [AVAnalysis] Add unit tests

* [AVAnalysis] Set PendingDeactivation after sending command

* [AVAnalysis] Harden the WebRTC client's session release and response

* [AVAnalysis] Tidy the WebRTC client's invoke path, callback visibility and logs

* [AVAnalysis] Align the WebRTC client and logic comments with the behaviour

* [AVAnalysis] Unit tests for the WebRTC client's sender

* [AVAnalysis] Exercise the WebRTC client's sender identity and remaining paths

* [AVAnalysis] Cancel the WebRTC client on destruction

* [AVAnalysis] Fix unit tests

* [AVAnalysis] Offer the analysis stream in VideoStreams

* [AVAnalysis] OnDeviceConnected now delegates to ContinueWithSession()

* [AVAnalysis] Answer parked commands on destruction, record VideoStreams

* [AVAnalysis] Correction in the interaction and callback

* [AVAnalysis] Invoke commands through the cluster in tests

* [AVAnalysis] Track session's video stream id

* [AVAnalysis] Drop dead client checks

* [AVAnalysis] Follow DisableContextTriggers as per spec

* [AVAnalysis] Fix the context-trigger persistence buffer and absent ZoneIDs

* [AVAnalysis] Answer an oversized ContextTriggers list with CONSTRAINT_ERROR

* [AVAnalysis] context-trigger tests

* [AVAnalysis] Fix clang error

* [AVAnalysis] Fix DisableContextTriggers

* [Camera] Adapt to the AV Analysis event source API

The AV Analysis cluster now records a session's source once, when the session
starts, and reports it on every event of that session.

* [AVAnalysis] Correctness fixes found reviewing the merge

* [AVAnalysis] Fix SourcestartTimestamp

* [AVAnalysis] Report failures from the test helpers instead of returning from them

* [AVAnalysis] Cover the zone handling, an absent delegate and a failed Startup

* [AVAnalysis] Fail a stream whose offer the camera refused

* [AVAnalysis] Report a failed activation

* [AVAnalysis] Refuse more supported contexts than the attribute allows

* [AVAnalysis] Refactor session storage

* [AVAnalysis] Share the logic's repeated lookups

* [AVAnalysis] Test IsTriggeringContextActive

* [AVAnalysis] Destroy the WebRTC client test fixture in dependency order

* [Camera] Simulate the WebRTC client for --camera-remote-analysis

* [AVAnalysis] Supply the WebRTCEndpointID in TC-AVANALY-2.5

---------

Co-authored-by: marktrayer <m.trayer@samsung.com>
* Fix minor PDC issues in the Network Commissioning cluster

- Align error codes with 1.7 spec (spec PR 12760)
- Optional to Nullable no longer compiles as an implicit conversion
- Fail correctly on ScopedMemoryBuffer identity allocation failure

Also add a chip_device_config_enable_wifi_pdc GN arg, always on for host
test builds, and unit tests for AddOrUpdateWiFiNetwork with PDC. Nothing
was compiling this code in CI, which is how it got into this state.

* Restrict chip_device_config_enable_wifi_pdc to Linux / Darwin

Other platforms may define this in CHIPDevicePlatformConfig.h
This is an interim measure so this code can be exercised in CI.

* Comment wording tweaks

* Fix some more bit rot

* Linux: Populate the PDC identifiers in the WiFi network iterator

These were never filled in, so the Networks attribute reported null
identifiers, and QueryIdentity / client identity reuse couldn't match an
existing network.

* Ensure failsafe disarm in test via MakeDefer
@silabs-matter-ci-bot
silabs-matter-ci-bot Bot requested a review from a team as a code owner September 16, 2026 00:46
@silabs-matter-ci-bot silabs-matter-ci-bot Bot added changing-git-submodules-on-purpose sl-require-admin-action This TAG indicates that an admin must take action. labels Sep 16, 2026
@github-actions

Copy link
Copy Markdown
Contributor

The check for sl-require-admin-action label CI failure for this job is normal. An admin must do the merge.

@Sarthak-Shaha
sarthak shaha (Sarthak-Shaha) merged commit c9df8a4 into main Sep 16, 2026
195 of 200 checks passed
@Sarthak-Shaha
sarthak shaha (Sarthak-Shaha) deleted the automation/update_main branch September 16, 2026 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changing-git-submodules-on-purpose sl-require-admin-action This TAG indicates that an admin must take action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.