@@ -537,7 +537,6 @@ jobs:
537537 - name : Clean out
538538 run : rm -rf out/
539539 - name : Run Tests using the python parser sending commands to chip-tool
540- # tests that failed macOS 15/26 last check: TestGroupMessaging,Test_TC_ACE_1_6,Test_TC_G_*,Test_TC_GRPKEY_*,Test_TC_S_*
541540 run : |
542541 sudo ./scripts/run_in_build_env.sh \
543542 "./scripts/tests/run_test_suite.py \
@@ -561,43 +560,9 @@ jobs:
561560 --energy-management-app ./objdir-clone/darwin-${{matrix.arch}}-energy-management-${BUILD_VARIANT}/chip-energy-management-app \
562561 "
563562
564- - name : Wait for port 9000 to be released from TIME_WAIT
565- # accessories.py doesn't use SO_REUSEADDR, so when the first test suite (running as root via sudo)
566- # closes the XML-RPC server on port 9000, the socket enters TIME_WAIT state owned by root.
567- # The subsequent test step (running as the 'runner' user) cannot bind to the same port until TIME_WAIT expires.
568- # This step waits for the kernel to release the port (TIME_WAIT = 2 * MSL (Maximum Segment Lifetime), typically 30-60 seconds on macOS).
569- # TODO: Add SO_REUSEADDR to accessories.py to eliminate this wait.
570- if : always()
571- run : |
572- echo "Checking TCP MSL (Maximum Segment Lifetime) setting..."
573- MSL_MS=$(sysctl -n net.inet.tcp.msl)
574- TIME_WAIT_SECONDS=$((MSL_MS * 2 / 1000))
575- echo "TIME_WAIT duration on this system: ${TIME_WAIT_SECONDS} seconds (2 * ${MSL_MS}ms MSL)"
576-
577- echo "Checking for processes on port 9000..."
578- lsof -i:9000 || echo "No processes found on port 9000"
579- echo "Checking for sockets (including TIME_WAIT) on port 9000..."
580- netstat -an | grep 9000 || echo "No sockets found on port 9000"
581-
582- # Wait for TIME_WAIT to clear, with a very generous safety margin for diagnostic purposes
583- # TODO: Once we have timing data, reduce this to a more reasonable value (e.g., +10 seconds)
584- MAX_WAIT=$((TIME_WAIT_SECONDS + 120))
585- echo "Waiting for port 9000 to be completely free (up to ${MAX_WAIT} seconds)..."
586- for i in $(seq 1 $MAX_WAIT); do
587- if ! netstat -an | grep -q "\.9000.*TIME_WAIT\|\.9000.*LISTEN"; then
588- echo "Port 9000 is free after $i seconds"
589- break
590- fi
591- if [ $i -eq $MAX_WAIT ]; then
592- echo "Warning: Port 9000 still in use after ${MAX_WAIT} seconds"
593- netstat -an | grep 9000 || true
594- fi
595- sleep 1
596- done
597-
598563 - name : Run purposeful failure tests using the python parser sending commands to chip-tool
599564 run : |
600- ./scripts/run_in_build_env.sh \
565+ sudo ./scripts/run_in_build_env.sh \
601566 "./scripts/tests/run_test_suite.py \
602567 --runner chip_tool_python \
603568 --include-tags PURPOSEFUL_FAILURE \
0 commit comments