Repository navigation
fix(mcp): honor HTTP tool call timeout - #1003
Merged
Merged
Conversation
Use the active operation's timeout for remote MCP requests so a successful handshake cannot shorten later tool calls.
Keep the published fix current without rewriting shared history.
vastsa
added a commit
that referenced
this pull request
Sep 24, 2026
Track active MCP tool calls by session, abort the local wait on session stop, and send notifications/cancelled to the server without closing a connection used by another session. Shared handshake waits can also be interrupted promptly. Rebased onto main (after #1003 and #1004), resolved transport signature conflicts to carry both timeoutMs and signal parameters, and fixed test file merge gaps. closes #1005
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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
Streamable HTTP MCP tool calls were cut off by the 10-second connection budget even after the handshake succeeded. Pass each request's operation budget to the HTTP transport, so
tools/callmay use its 100-second limit while initialization remains bounded to 10 seconds.The regression test uses a delayed local HTTP MCP server and verifies that a call outlasting the handshake budget succeeds. Redirect and timeout handling retain their existing permission checks.
Specs and validation
Updated the MCP plugin security specification and E2E-024K scenario in English and Chinese.
pnpm build:js, desktop typecheck, and lint passed.pnpm docs:checkfails on currentorigin/mainbecause the new English UI design-system tables lack matching Chinese tables; this PR does not touch that page.MCP-focused tests: 60/60 passed; isolated Electron trusted-extension E2E: 39/39 passed.
On upstream main
03e03d4, the GitHub JS job fails the existing architecture budget:apps/desktop/electron/main/index.tshas 1503 lines (limit 1500). These PRs do not change that file. PR base and Rust CI checks pass.The agent-facing delayed MCP tool journey remains a Draft E2E scenario; no macOS/Linux run was performed. No persisted format or public API changes.