Skip to content

fix(tests): stop solver groups after isolated module exit - #2906

Merged
Mister-Meeseeks merged 2 commits into
CrocSwap:mainfrom
petalas:research/isolated-exit-cleanup-20261016
Oct 16, 2026
Merged

Mister-Meeseeks merged 2 commits into
CrocSwap:mainfrom
petalas:research/isolated-exit-cleanup-20261016

Conversation

@petalas

@petalas petalas commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

Summary

Stop ordinary POSIX child solvers after an isolated unittest module finishes, even when its leader has exited and its descendants have closed the capture pipes.

 module reaches pipe EOF
+ stop its owned POSIX process group
 remove leader from active registry
 return the original status/output

The production change is seven lines in scripts/run_isolated_tests.py. Six real-process regression tests and the evidence note retain the reproducer, source hashes, commands, overlap and limitations. Cleanup denial cannot produce PASS. Windows behavior, mathematical inputs and the selected frontier are unchanged.

Started from canonical main b2024b853ae33de489756de8e4dde011dabebeaa, revision 5. Refreshed onto a98b1ebcdd6f2fe25ffdd30cd7e753ebfe319797 after PR2579 was incorporated; its completion receipts, cancellation handling and historical overlay are preserved. Credit Aaron Wang/navinor's scheduler, woklerx's assertion guard and ywz65's PR2625/2579 work. PR2377/2469 concern the separate registered-package runner.

Canonical investigation and claim. The verifier-engineering card's scope change and fresh overlap coverage are recorded in the note.

Evidence

  • Before: both unchanged main checkpoints fail four of the six new tests. A successful CLI exit leaves a ready child and grandchild alive; the next queued module also detects them.
  • After: all six tests pass on Linux using retained pidfds, including parent-only cleanup and cleanup-denial controls. Normal and optimized CPython 3.12.15 pass; optimized 3.13.5 also passes.
  • All 28 focused lifetime/cancellation/completion/historical-overlay tests and 144 research-workflow tests pass on refreshed main. Selected source-binding baseline and focused Ruff correctness checks pass.
  • Full isolated run attempted all 162 modules. Twelve fail, and all twelve reproduce on unchanged refreshed main with the same underlying failures. The note lists them and distinguishes the run-specific completion-receipt diagnostic. The other 150 processes exit zero. No tracked artifact regeneration occurred. This is not a green full-suite claim.

Merge Danger

Door: two-way.

Blast Radius: verifier.

Completed modules' background processes in their owned POSIX group are now killed deliberately. Modules must still await proof-relevant children and propagate their failures; cleanup is not evidence of successful verification. Detached groups, Windows orphan containment, macOS and hosted CI are unverified. The selected cold replay was not run, and no new kappa is claimed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants