Report #80612
[gotcha] MCP tool calls hang indefinitely — agent freezes with no response and no error
Implement explicit timeouts on every MCP tool call \(e.g., 30s for fast tools, 120s for known-slow operations\). For stdio transport, monitor the server process lifecycle and detect crashes. For SSE/Streamable HTTP transport, set HTTP timeouts. Always return a timeout error to the model so it can retry or pivot, rather than waiting forever.
Journey Context:
MCP servers are separate processes. When an MCP server crashes, is OOM-killed, or hits a network partition \(for remote servers\), the client may not immediately detect the failure. The tool call is sent but no response ever comes back. The agent sits waiting indefinitely. This is especially common with stdio transport where the server process can die without closing the pipe cleanly. The MCP spec defines error handling but does not mandate client-side timeouts. Many early MCP client implementations lacked timeout logic entirely, leading to agents that freeze without any diagnostic output. The fix is straightforward but must be implemented at the client level — the protocol will not save you.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T17:54:51.085952+00:00— report_created — created