You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test(messaging): hold live waits for the MCP concurrency bound - #8851
Hold each of four logical codex_wait_reply operations at its first reply RPC before asserting that a fifth operation is rejected as busy. Counting completed metadata reads could include repeated snapshots or operations that had already released their slots.
Verify four distinct live helpers and four unsettled promises, then disconnect and verify that every wait settles, no additional RPC is issued, and the observed helpers exit.
Keep the runtime's four-operation limit, deadlines, and platform guard unchanged. This test-only follow-up addresses the concurrency assertion seen in CI job 133486103455.
Verification
bun run typecheck: passed, 2,562 files.
bun run structure:check and bun run privacy:scan: passed.
Inspected the wait lifecycle and fixture together: the new barrier holds the first reply RPC for each logical wait, and the assertions check that those operations remain pending.
Linux CI 43927823740: the updated concurrency/disconnect case executed and passed. The affected test groups completed with 84 passes / 334 assertions and 9 passes / 85 assertions.
The CLI MCP suite retains its Windows skip. The full local suite was omitted on the shared Windows host; the affected POSIX runtime checks were executed by Linux CI.
Checklist
Scope stays focused and avoids unrelated cleanup.
Docs or release notes were updated when needed.
Security-sensitive changes were reviewed for secrets, auth, and unsafe defaults.
Summary by CodeRabbit
Tests
Expanded coverage for concurrent MCP waits, verifying that four waits can remain active, additional waits are rejected at the limit, and disconnects settle pending requests.
Updated queue test scenarios to keep the initial reply pending until disconnection, covering behavior in both relevant wait modes. These changes strengthen validation of concurrency limits and disconnect handling without changing user-facing functionality.
No actionable comments were generated in the recent review.
Walkthrough
The MCP wait-concurrency test now blocks four requests at reply RPCs, verifies that a fifth request is rejected while those requests remain active, and checks that disconnect settles all four.
The fixture holds reply RPCs in the wait-bound barrier mode. The test confirms that four waits remain active, a fifth is rejected, and disconnect settles the pending requests.
lidge-jun/opencodex#8090: Adds the codex_wait_reply operation and its four-slot concurrency limit, which this test exercises.
Suggested reviewers:hojooonkim
Merge Risk: Minimal · up to 35200
This change only tightens a test for the MCP concurrency limit and does not alter production behavior. It carries little merge risk.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title names the test-only change: holding live waits at the MCP concurrency bound. The raw summary confirms the test now holds four waits at their first reply RPC, checks a fifth is rejected, and …
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title names the test-only change: holding live waits at the MCP concurrency bound. The raw summary confirms the test now holds four waits at their first reply RPC, checks a fifth is rejected, and verifies disconnect settles all four. The title matches the main change and is specific enough for a reviewer scanning history.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
Reviewing files that changed from the base of the PR and between 5b864ad and 3520078.
Files selected for processing: 2
tests/cli/cli-message-mcp.test.ts
tests/helpers/messaging-mcp-queue.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
choreMaintenance, CI, tests, refactors, or build changes (not a user-facing bug or feature).
2 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
codex_wait_replyoperations at its first reply RPC before asserting that a fifth operation is rejected as busy. Counting completed metadata reads could include repeated snapshots or operations that had already released their slots.Verification
bun run typecheck: passed, 2,562 files.bun run structure:checkandbun run privacy:scan: passed.Checklist
Summary by CodeRabbit