[codex] fix(tests): stabilize local interrupt cleanup check - #39496
[codex] fix(tests): stabilize local interrupt cleanup check#39496sweetcornna wants to merge 1 commit into
Conversation
87e5068 to
acb454c
Compare
teknium1
left a comment
There was a problem hiding this comment.
Thanks for addressing the cross-platform and CI-stability concerns. The timeout increase targets a real 30-second wait in tests/tools/test_local_interrupt_cleanup.py:52.
Problems
- The module-wide
pytestmarkin this PR would skip the newer Windows regression test attests/tools/test_local_interrupt_cleanup.py:100-123on native Windows. That test was added bye5253d852to verify Windows process-tree cleanup, so it should remain runnable there.
Suggested changes
- Resolve the file conflict and scope the POSIX skip markers to only the POSIX-dependent tests at lines 68 and 126. Keep
test_kill_process_uses_windows_tree_killactive, and keep the 75-second timeout on the live POSIX test.
Automated hermes-sweeper review.
| @@ -22,6 +22,11 @@ | |||
|
|
|||
| from tools.environments.local import LocalEnvironment | |||
|
|
|||
| pytestmark = pytest.mark.skipif( | |||
There was a problem hiding this comment.
This module-wide skip would also skip current main's test_kill_process_uses_windows_tree_kill (tests/tools/test_local_interrupt_cleanup.py:100-123, added by e5253d852) on Windows, removing the regression coverage that platform needs. Please scope this skip to the two POSIX-dependent tests instead.
acb454c to
ae5dff3
Compare
|
Rebased and reworked this onto current main ( Validation: Windows 2 skipped; Linux/WSL 2 passed; canonical targeted runner, Ruff, |
Summary
os.getpgid/os.killpgdo not existos.killpgprobe as an intentional Windows-footgun scanner exceptionRoot cause
tests/tools/test_local_interrupt_cleanup.pydirectly uses POSIX-only process-group APIs. On native Windows, current main fails both tests before reaching the behavior under test becauseos.getpgidandos.killpgare absent.The earlier branch also added a per-test
pytest-timeoutmarker. Current main removedpytest-timeoutin2f9d18711and now bounds each test file throughscripts/run_tests_parallel.py(300 seconds), so the rebased patch follows that current policy instead of restoring a stale marker.Current-main integration
11089899fbb3ec1c043427c680e8fd8f4cab06c939975613b; this patch does not remove or skip any current Windows-specific testValidation
.venv\Scripts\python.exe -m pytest tests\tools\test_local_interrupt_cleanup.py -q(Windows 11: 2 skipped)wsl -e sh -lc "cd /mnt/d/project/hermes/hermes-agent-work && UV_PROJECT_ENVIRONMENT=/tmp/hermes-pr39496-uv-env uv run --extra dev --extra all python -m pytest tests/tools/test_local_interrupt_cleanup.py -q"(Linux/WSL: 2 passed)scripts/run_tests.sh tests/tools/test_local_interrupt_cleanup.py -q(canonical runner: file passed).venv\Scripts\ruff.exe check tests\tools\test_local_interrupt_cleanup.py.venv\Scripts\python.exe -m py_compile tests\tools\test_local_interrupt_cleanup.py.venv\Scripts\python.exe scripts\check-windows-footguns.py --diff upstream/maingit diff --check upstream/main...HEADIndependent review found no high-confidence issues.