anthropics / anthropics/claude-ai-mcp
Tool-call results cross-wired between concurrent chats (remote connector, claude.ai web) — user shown another conversation's answer
- Lingua principale
- Nessun dato sulla lingua
- Stelle
- 471
- Fork
- 77
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
## Environment
- claude.ai web, remote MCP connector (Streamable HTTP transport), OAuth
- Multiple chats open in separate browser tabs, same connector, same user
## Summary
When two chats call the **same** MCP tool in parallel, the result of one chat's tool call is delivered to the *other* chat. The receiving chat renders a coherent-but-wrong answer — no error, no warning. This is a silent data-integrity failure, not a cosmetic one.
## Steps to reproduce
1. Connect a remote MCP connector exposing a stateful Q&A tool (e.g. `ask_needl`).
2. Open three chats in three tabs.
3. In each, ask about a different entity (Tab 1: "Bajaj Finance…", Tab 2: "JSW Steel…", Tab 3: "IndusInd Bank…"), triggering the tool nearly simultaneously.
**Expected:** each chat receives the result of its own tool call.
**Actual:** results are mismatched across tabs — Tab 1 (Bajaj) rendered another tab's answer, etc. Reproduced across all three tabs.
## Server-side verification (ours)
- Each tool call was processed correctly and independently; every session in our store is single-topic and correct when opened in our own app.
- Our server is fully request-isolated (per-request context, no shared state) and echoes the JSON-RPC request `id` unchanged. The mixup is purely in client-side response routing.
## Likely root cause
Appears to be the missing conversation/session identifier described in anthropics/claude-code#41836: the client doesn't echo `Mcp-Session-Id` and sends no per-conversation identifier, so concurrent conversations over one connector are indistinguishable and responses can be correlated to the wrong chat. It only manifests when the **same tool** is invoked concurrently, which suggests correlation is keyed on something other than the JSON-RPC request `id`.
## Impact
Silent wrong answers across concurrent conversations — a correctness/trust issue for any deployed connector, especially in financial/regulated contexts.
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Start with the three-tab reproduction described in the issue, using the remote MCP connector and a stateful Q&A tool. Trace client-side response routing for concurrent calls to the same tool, including JSON-RPC request IDs and the missing MCP session or conversation identifier. Done means each concurrent chat consistently receives only its own tool result, without cross-conversation responses.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Ambito
- api, distributed-systems
- Tipo di issue
- Bug
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Tranquilla
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 32/100