Repository navigation
Fail semantic runs that exit without a trustworthy result (SEMANTIC-RUNNER-COMPLETION) - #1437
Conversation
|
Reviewed 84f8fee: run_semantic_tests.py now takes the verdict from the child's AI-assisted review. Recommendation: Merge |
|
Hi @titoreinaldo, thanks for this. #1749 by Could you rebase it? When you do, please also add the case #1749 tests and yours does not: a module whose worker exits with status 0 in the middle of a test (yours exits at import) next to a healthy module under AI-assisted (Claude Code, Claude Opus 5.5) |
Retain process tracking and interrupt/timeout handling from main.
Include a worker that exits zero mid-test next to a healthy module under -j 2. AI-assisted.
84f8fee to
53bc0e3
Compare
|
I ran |
|
Merged into Checked before merging: Tested in our local release candidate (main + 41 PRs): translator suite 512 files / 6,442 tests clean, Python suite with no new failure versus main, and 360 s game runs on an RTX 5080 with no regression. Note: #2073 touches the same lines of AI-assisted (Claude Code), posted for DadaCap. |
Claimed in the coordination issue as: SEMANTIC-RUNNER-COMPLETION (#14 claim).
What and why
An incomplete semantic run can report success. A synthetic module calling
os._exit(0)during import leaves no unittest result; the parallel runner counts zero for that worker and accepts its process status, and the serial runner simply forwards success. An exit handler can also overwrite the status after unittest has completed with a failure.Use unittest’s completed result as well as the process exit status in both modes. Status 0 without a result, or after unittest reported a nonzero status, is an error. Empty package initializers are still ignored based on the recorded result, and timeouts retain their existing diagnostics. Discovery rules are unchanged.
Tested
1154976dwith either-j 1or-j 2: four false-green cases before, all four detected after.python -I tests/test_run_semantic_tests.py: 24 tests pass.python -I scripts/run_semantic_tests.py tests/semantic -j 8: 476 files, 6,223 tests, zero failing files.GPUs tested: none, Linux x86-64 / Python 3.12.14, CPU-only. No game files, keys, decryption, or online game services. AI-assisted: yes, OpenAI Codex.