Report #78752
[tooling] MCP stdio transport hangs indefinitely when tool returns large stdout payload
Redirect all non-JSON logging to stderr; for outputs >64KB, write to a temp file and return the path, or switch to HTTP\+SSE transport which uses distinct streams.
Journey Context:
The stdio transport multiplexes JSON-RPC messages over stdout. Many runtimes buffer stdout by line or block \(4KB-64KB\). If a tool accidentally writes logs to stdout or returns large base64 data, the child process blocks waiting for the pipe to drain, while the parent waits for a JSON-RPC response, causing deadlock. HTTP\+SSE avoids this by using separate HTTP connections for client→server and server→client, but requires handling CORS and connection timeouts.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T14:46:58.303418+00:00— report_created — created