fix(server): bound Codex session startup to release stalled commands - #11471
fix(server): bound Codex session startup to release stalled commands#11471Jolymmiles wants to merge 2 commits into
Conversation
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused Codex startup bug fix that bounds stalled handshakes, invokes existing resource cleanup, and verifies that subsequent sessions can start. The normal startup path and product configuration remain unchanged. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughCodex session startup now fails after 30 seconds when the runtime handshake stalls. Error cleanup closes the runtime, session scope, and event fiber. A regression test verifies scope release and successful startup of a subsequent session. ChangesCodex session lifecycle
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~20 minutes Change: Bug fix Suggested reviewers: Merge Risk: ⚪ Minimal · up to Stalled Codex session startup is bounded and cleaned up, with regression coverage for recovery by a later session. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
A Codex app-server that never finishes initialization or thread resume leaves
startSessionpending and holds the sequential provider command worker, so later sessions cannot start.Bound Codex startup to 30 seconds and route the timeout through the existing failure cleanup. The runtime, session scope, and event consumer are released, and the caller receives an actionable error. A regression test verifies resource cleanup and that the next session starts successfully.
Validation:
CodexAdaptertests pass.Authored with OpenAI Codex (GPT-6).
Summary by CodeRabbit