Repository navigation
fix(mcp): guide client and provider timeout recovery - #5608
Conversation
Teach client deadline recovery at initialization and on the static JavaScript tool. Name the producer-owned server budget, preserve partial Evidence and cleanup uncertainty, and avoid making an unavailable Evidence reader a retry prerequisite. Cover initialization delivery and real CLI/MCP timeout behavior. Fixes #5598 Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing)
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 24e32b26d5
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
[Medium impact] The PR appears safe to merge; the previous timeout-command issue is fixed, and no new actionable failure was found. SummaryThe PR separates client deadlines from REA’s server/provider deadlines and teaches recovery before a host can discard the response.
Reviews (2) · Last reviewed commit: "fix(errors): avoid invented controls in ..." · Reviewed by Greptile |
Generic timeout errors cannot know whether the caller can change a budget. Keep their remediation valid for fixed limits and leave exact adjustable controls to the producer-owned override. Name the CLI command that supports the JavaScript timeout flag instead of implying the analyze shorthand does. Cover both counterexamples without changing error identity or cleanup semantics. Refs #5598 Assisted-by: Kogasa (gensokyo-skills:kogasa-surprise-testing)
|
Final reviewed head: Both actionable automated findings were fixed and resolved after regression proof. Final source was additionally reviewed through an independent Codex CLI pass with no actionable P1/P2 findings. All 79 focused tests, complete local static/architecture checks, generated-document checks and skill validation passed. Thirty actual agent trials are retained; final layered 8/8 plus post-review 2/2 passed the scoped recovery oracle. Details and performance limits: #5598 (comment). Fresh The task owner explicitly authorized ready-for-review submission, continued work and administrative bypass when appropriate. No independent human final-diff review is asserted, and unchecked human declarations are not silently filled. External checks still queued/running are not reported as passed. If normal merge remains blocked solely by those checks/declarations, the owner-authorized override is used with this verification limitation recorded. |
Summary
Fixes #5598. Teach recovery before a host deadline can discard REA's error. The issue records a pinned, cloned RepoPrompt CE comparison and actual Codex counterexamples.
Problem and expected behavior
With a 1-second Codex MCP deadline, the old agent repeated an identical failed analysis without identifying the client setting. Returned provider errors also blurred the two deadline owners. An unavailable partial-Evidence reader must not block a corrected static retry.
Change and scope
tool_timeout_sec, not serveranalysis_timeout_ms.Contract and boundary impact
Owner: initialization/catalog teaching surfaces; JavaScript timeout producer; shared domain error presentation.
Scope: routine usability fix; no new provider/capability or maintainer scope decision needed.
CLI/MCP: same error/schema identities, argument types, results, and caller choices. No discovery tool or repeated full schema payload added.
Evidence/provenance/cleanup: unchanged; partial references stay usable; unknown work/cleanup stays unknown. No execution, installation, configuration, or target-authority expansion.
Generated metadata: authored skill 44 and tracked package metadata; ignored catalogs/skills regenerated, not committed.
Documentation or usability only; no target interaction.
Evidence and regression coverage
codex-cli 0.161.0,gpt-6.1-sol, Node 24.18.0; Commander 14.0.3, static only. Fresh processes, serial bounded-heap trials. Full calls and receipts retained locally; outcome/performance summary linked in the issue after final qualification.Validation performed
npm run test:focused -- tests/boundary/mcp/javascriptAnalysisResources.test.ts tests/acceptance/applications/javascriptAnalysisLimits.test.ts tests/boundary/mcp/webBundleContainmentMcp.test.ts tests/boundary/mcp/targetContentFramingMcp.test.ts src/domain/analysisErrorProjection.test.ts src/server/EvidenceMcpServer.test.ts— 79 tests passed; the refactored resource file additionally rerun.npm run check— passed (typecheck, lint, format, knip, metadata, architecture/module boundaries).npm run docs:generate/npm run docs:check— passed.npm pack --dry-run --json— passed.Compatibility, safety, and release
No breaking changes or new runtime work/cache. Startup teaching costs extra context; whole-task tokens, wall/CPU time and sampled family RSS are reported, not inferred from bytes. No real Hopper/Ghidra/macOS qualification: unavailable-provider probes only test deliberate missing-install preflight; RepoPrompt research is source-only. Underlying analysis semantics are unchanged.
Author readiness
Human owner: @gensokyo-dev (task owner's explicitly selected account).
The task owner explicitly directed ready-for-review submission and delegated continuation/merge, including bypass when appropriate. Automated review and executed evidence are reported above; no separate human final-diff review is asserted by this agent.
Before merge