Repository navigation
ci: pick mutmut's process isolation per platform (ADR-1122) - #911
Conversation
#906 set process_isolation = "forkserver" for every platform. On macOS that aborts before any mutant runs: the stats run, now in a forked child, imports sentence_transformers, whose torch.backends.mps.is_available() ends in SIGABRT (Child exited with code -6). Local runs on macOS, the autopilot's included, could no longer run the gate. mutation_check.sh now rewrites process_isolation from ci_mutation_scope.py: forkserver on Linux (fork hangs in torch autograd there), fork on macOS (measured again: 11 mutants of #878, 76 s, 0 timeouts). Any other platform stops the gate instead of guessing.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Claude finished @cdeust's task in 2m 33s —— View job PR #911 review (1 of 3)
No Blockers. The review leaves three notes for after merge, all about tests. One concerns the I could not run pytest, ruff or the craftsmanship gate in this job (permission denied), so the review comes from reading the code. Verdict: approve |
Review 1 of 3: PR #911 (ADR-1119 contract)I ran five reviews: code quality, security, test coverage, documentation and performance. No Blockers. What I traced:
I could not run pytest, ruff or the craftsmanship gate in this job (permission denied), so these findings come from reading the code. The Pipeline run was still in progress when I wrote this. Notes, no action before merge
Verdict: approve |
…-per-platform # Conflicts: # CHANGELOG.md
|
Claude finished @cdeust's task in 1m 42s —— View job PR #911 review (2 of 3)
No Blockers. The only new commit is a merge from main. It keeps both CHANGELOG entries, and #910's
I could not run pytest, ruff or the craftsmanship gate in this job (permission denied), so the review comes from reading the code. Verdict: approve |
Review 2 of 3: PR #911 (ADR-1119 contract)No Blockers. Review 1 had none either. What changed since What I checked:
As in review 1, I could not run pytest or ruff in this job, so these findings come from reading the code. Notes, no action before merge
Verdict: approve |
Problem: a regression from #906 on macOS
#906 set
process_isolation = "forkserver"for every platform. On macOS this mode aborts before any mutant runs. The stats run now executes in a forked child; there, importingsentence_transformerscallstorch.backends.mps.is_available(), which ends in SIGABRT:The result is that no local run on macOS can execute the gate any more, including the autopilot's checks (
GITHUB_BASE_REF=main python scripts/ci_mutation_diff.py). The Linux CI is not affected.Fix
mutation_check.shalready rewrites[tool.mutmut]before each run. It now also rewritesprocess_isolation, taking the value fromscripts/ci_mutation_scope.pyISOLATION_BY_SYSTEM:forkserverfork: 5 timeouts in the first 7 (child idle in torchbackward());forkserver: 0 of 11forkforkserver: SIGABRT before any mutant runs;fork: 0 timeouts in 11, gate run 76 s (9 killed, 2 survived)Any other platform stops the gate with an error. There is no silent fallback to a mode nobody has measured.
Tests
test_mutmut_sees_the_isolation_of_this_platform(on every bash on the host): thepyproject.tomlthat mutmut reads carries this platform's value.test_each_measured_platform_has_its_isolationandtest_an_unmeasured_platform_stops_the_gate.test_mutation_isolation.py: the line the gate rewrites exists inpyproject.tomland is valid for mutmut.ruff checkandruff format --checkpass on the touched files, and so doesscripts/check_craftsmanship.py.ADR-1122 (wiki page and mirror) and the CHANGELOG are updated.