project-chip / connectedhomeip

Matter (formerly Project CHIP) creates more connections between more objects, simplifying development for manufacturers and increasing compatibility for consumers, guided by the Connectivity Standards Alliance.
https://buildwithmatter.com
Apache License 2.0
7.48k stars 2.01k forks source link

[BUG] TC_EEVSE_2_3 does not run on EST timezone #35623

Open andy31415 opened 1 month ago

andy31415 commented 1 month ago

Reproduction steps

Running something of the form:

scripts/run_in_python_env.sh out/venv './scripts/tests/run_python_test.py --load-from-env out/test_env.yaml --script src/python_testing/TC_EEVSE_2_3.py'

fails on my machine with:

│      [2024-09-17 09:55:12.771290][TEST][STDOUT]    return fut.result()                                                                                                                                                                             │
│      [2024-09-17 09:55:12.771296][TEST][STDOUT]           ^^^^^^^^^^^^                                                                                                                                                                             │
│      [2024-09-17 09:55:12.771301][TEST][STDOUT]  File "/usr/local/google/home/andreilitvin/devel/connectedhomeip/src/python_testing/TC_EEVSE_2_3.py", line 270, in test_TC_EEVSE_2_3                                                               │
│      [2024-09-17 09:55:12.771307][TEST][STDOUT]    asserts.assert_less(next_start_time_epoch_s,                                                                                                                                                    │
│      [2024-09-17 09:55:12.771313][TEST][STDOUT]  File "/usr/local/google/home/andreilitvin/devel/connectedhomeip/out/venv/lib/python3.11/site-packages/mobly/asserts.py", line 191, in assert_less                                                 │
│      [2024-09-17 09:55:12.771319][TEST][STDOUT]    _call_unittest_assertion(                                                                                                                                                                       │
│      [2024-09-17 09:55:12.771325][TEST][STDOUT]  File "/usr/local/google/home/andreilitvin/devel/connectedhomeip/out/venv/lib/python3.11/site-packages/mobly/asserts.py", line 50, in _call_unittest_assertion                                     │
│      [2024-09-17 09:55:12.771331][TEST][STDOUT]    raise signals.TestFailure(my_msg, extras=extras)                                                                                                                                                │
│      [2024-09-17 09:55:12.771337][TEST][STDOUT]mobly.signals.TestFailure: Details=779934015 not less than 779929140, Extras=None

The comparison of times seem to be timezone dependent. This prevents me from being able to "run all CI tests" on my machine.

Bug prevalence

Always

GitHub hash of the SDK that was being used

514e810a7cfd3a8c99f612cbfe51a4e403f2ffd5

andy31415 commented 1 month ago

Specifically setting TZ=UTC makes the test pass however setting TZ=EST causes the faiulure for me.

andy31415 commented 2 weeks ago

@jamesharrow could you please check this?