Repository navigation
[CI] Make SSH permission probe fixture independent of real PID reuse - #26190
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (1)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 1 remain after this review. 📝 WalkthroughWalkthroughThe permission-denied liveness test now stubs Priority: ⬇️ Low Merge Risk: ⚪ Minimal · up to This test-only change makes the permission-denied check independent of real PID reuse while retaining the 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ELI5
The SSH permission test sometimes tested PID reuse instead of permission denial. It invented PID4242, mocked
kill, and then consulted the runner's real process table. If another process occupied that PID, the identity check correctly returnedDEADbefore the mocked permission check could run.What Changed
The permission fixture now also supplies a matching slot identity for exactly
ps -o args= -p 4242. Other ps queries refuse; it never consults a real PID. The locale-sensitive denied signal mock andUNKNOWNassertion remain unchanged. The adjacent real-process PID-reuse test still expectsDEAD.Why
Permission handling needs a known process identity. Making both observations deterministic preserves that boundary and avoids depending on which processes the CI runner happens to start. It adds no process, wait, production change or relaxed assertion.
Linked Issue
CI failure in https://github.com/stablyai/orca/actions/runs/37606869393/job/112745317690 (composer performance PR#26179).
Visual Proof
N/A — test fixture only; no application behavior or UI change.
Testing
Before/after evidence (correctness and reliability; no performance claim):
UNKNOWNexpected,DEADreceived)The controlled red model explicitly supplies an unrelated command for the invented PID, reproducing the incomplete fixture. It does not demonstrate a production permission bug: production's PID-reuse branch correctly classifies that different identity. The corrected fixture exercises permission handling with a matching slot identity and still expects
UNKNOWN.-t; the other29 native-process cases are unexecuted locally, not removed from CI.4355e65b, tested merge sourceb125d4f9(incoming main2584ed90plus this head). The actual Bun SSH module passes all30 cases (7.103s, no skips). Canonical discovery and all five assignments cover all11,678 physical files exactly once: 11,538 passing files,140 existing skipped files;112,608 passing cases,one expected failure,1,052 existing skipped cases,zero unhandled errors. Every11,669 prior-source file remains with nine incoming additions and no removals. Runtime configuration is unchanged:10,552 Bun files,1,125 actual Node runtime files,one Node measurement file. Stock artifacts establish file enrollment and raw counts; selected local reports separately preserve exact permission-case identity.Review
Exact failed synthetic source
c08333f6c7aaeaee20625140771ad16e8364afafhas incoming main5cafefe726a28bc0052aed5255bfce1cd8fcfb42. That main introduced this case; the composer change did not edit it. Prepared against main520033b0e12a752036b40dd4cf53dac47ba2fd3b. Independent source review is clear: exact modeled identity, original permission assertion and real PID-reuse coverage retained. Final head has green applicable checks and a clean merge state. Zero review threads were observed; no bot review completion is claimed.Agent skill upstream boundary
Notes
The owning-host distinction between live, unverifiable and exited is unchanged. Windows implementation, remote protocol, SSH runtime routing and stop behavior are unchanged. Real lifecycle/teardown validation stays in isolated full CI.
Checklist