[BUG] Claude.ai MCP Client: Non-deterministic GET/POST sequencing causes false tool execution errors (Streamable HTTP)
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Claude_ai_MCP_Client_Transport_Inconsistency_Report_v3.pdf
Summary
The Claude.ai MCP client (Streamable HTTP transport, spec 2025-03-26) exhibits non-deterministic behavior when invoking tools on a compliant MCP server, causing false tool execution errors reported to the user while the server processes all requests successfully.
Environment
Claude.ai web interface (claude.ai)
MCP server: Custom VB.NET HttpListener implementation
Transport: Streamable HTTP via Tailscale Funnel (HTTPS)
Protocol version: 2025-03-26
Three issues identified:
Non-deterministic GET/POST ordering: The client sometimes sends GET before POST, sometimes POST before GET, sometimes POST without GET. No consistent pattern.
Abandoned requests (GET without POST): The client opens an SSE stream (GET with Accept: text/event-stream) but never sends the corresponding POST with the tool invocation. Server waits normally. Client reports error.
False error on successful execution: Server receives POST, executes BLE command, writes JSON response, closes connection — all confirmed via timestamped logs. Client reports "Error occurred during tool execution" to the user despite the server completing successfully.
Evidence
All issues documented with millisecond-precision server logs showing complete request lifecycle. After fixing the only server-side bug (cross-thread UI logging exception), the server achieves 100% success rate on all received requests. All remaining failures originate from the client transport layer.
Full technical report with logs, debugging methodology, and compliance verification attached as PDF.
What Should Happen?
Every tool invocation should follow a deterministic request sequence. The client should either:
- Send GET (SSE) then POST (tool call) consistently, OR
- Send POST only when SSE is not required
The client should never:
- Send GET without a subsequent POST (abandoned request)
- Report an error to the user when the server has successfully responded with a valid JSON-RPC response and closed the connection cleanly
Error Messages/Logs
Client-side error shown to user:
"Error occurred during tool execution"
Meanwhile, server log for the same request shows complete success:
[LISTENER] Recibida: POST
Body: {"method":"tools/call","params":{"name":"device_move","arguments":{"mode":"4","velocity":100}},"jsonrpc":"2.0","id":1}
[BLE] Antes WriteValueAsync
[BLE] ✅ Device command sent successfully
Response: {"jsonrpc":"2.0","id":1,"result":{"content":[{"type":"text","text":"Device: Mode=4, V=100"}]}}
[RESPONSE] Antes de escribir
[RESPONSE] Escrita OK
[RESPONSE] Cerrada OK
[LISTENER] Procesada OK
[LISTENER] Esperando petición...
Server completed: BLE command executed, JSON response written, HTTP connection closed. Zero errors.
Client reported: failure.
Steps to Reproduce
- Implement a compliant MCP Streamable HTTP server (spec 2025-03-26)
- Expose it via HTTPS (e.g. Tailscale Funnel)
- Connect it to Claude.ai as an MCP integration
- Execute 5+ rapid sequential tool calls in a single conversation turn
- Observe: some calls succeed, some report "Error occurred during tool execution"
- Check server logs: ALL requests processed successfully with valid JSON-RPC responses
The failure is non-deterministic. It typically appears after 4-6 sequential calls in the same response, but the exact call that fails varies between sessions.
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
N/A — bug is in Claude.ai web client MCP transport, not Claude Code
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
Other
Additional Information
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗