Skip to content

fix(mcp): fail in-flight calls when resume exhaustion redials - #1477

Merged
TheGreatAxios merged 2 commits into
mainfrom
cl-10758-provider-mcp-residuals
Oct 17, 2026
Merged

TheGreatAxios merged 2 commits into
mainfrom
cl-10758-provider-mcp-residuals

Conversation

@TheGreatAxios

@TheGreatAxios TheGreatAxios commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator

Resume exhaustion still notifies the owner to redial, and an in-flight HTTP request rejects with MCP error -32000 (Connection closed) because close no longer replaces the SDK onclose wrapper.

Part of CL-10758

@linear-code

linear-code Bot commented Oct 17, 2026

Copy link
Copy Markdown

CL-10758

@corbits-triage

corbits-triage Bot commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

Triage: Pass

No changes needed from you. A maintainer will review this pull request.

@TheGreatAxios TheGreatAxios left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review · Request changes

Three behavior changes in one diff: the Codex 429 retry floor, MCP SSE resume exhaustion, and the same-origin redirect pin. Triage already failed the mix. The session.ts note is a comment-only drive-by.

Findings

  • src/mcp/client.ts:453 — disarmTransportDeathSignal noops onclose before Protocol.close. Resume exhaustion still redials, but an in-flight HTTP call stays pending until the SDK request timeout. Stdio death fails that call because onclose already ran. The new tests drive a plain object, so they miss this.

Leave the SDK onclose wrapper in place so Protocol._onclose rejects an
in-flight HTTP request with MCP -32000 when resume exhaustion redials.
@TheGreatAxios
TheGreatAxios force-pushed the cl-10758-provider-mcp-residuals branch from f111055 to cfbc014 Compare October 17, 2026 01:39
@TheGreatAxios TheGreatAxios changed the title fix: harden provider retry floors and mcp resume signals fix(mcp): fail in-flight calls when resume exhaustion redials Oct 17, 2026

@TheGreatAxios TheGreatAxios left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review · Approve

Resume exhaustion still redials, and an in-flight HTTP call rejects with connection closed instead of staying pending. The diff is only that slice.

No findings.

@TheGreatAxios
TheGreatAxios merged commit cb23247 into main Oct 17, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant