Reap child when capture_output errors in CommandRunner::run - #401
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthrough
ChangesCommand runner cleanup
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to The change ensures a child process is cleaned up before a capture error is returned, preventing lingering processes without introducing an identified merge-blocking risk. It is merge-ready after normal checks and review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Closes #400.
The early
?oncapture_outputinCommandRunner::runpropagated errors immediately, dropping theChildwithoutkill()/wait()— a zombie on Unix until parent exit. Now routes the error throughfinish_child(the same kill+wait+recover teardown used by every other path since #398/#399) before propagating.Verification:
cargo build,cargo clippy --all-targets -- -D warnings, andcargo test(1365 passed) all green on a clean origin/main + this patch. Note: the current repo checkout carries unrelated concurrent WIP inrust/src/logging.rsthat fails to compile on its own; it is not part of this PR.Summary by CodeRabbit