anthropics / anthropics/claude-ai-mcp

MCP tool calls rejected when tool declares outputSchema/execution (sequential-thinking ≥2025.11.25)

Aperta
#673 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
bug
Lingua principale
Nessun dato sulla lingua
Stelle
471
Fork
76
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

### What happened?

Tool calls to an MCP server are rejected when the tool definition declares outputSchema/execution fields (observed with sequential-thinking server version ≥2025.11.25). The error returned is a generic "Failed to call tool," with no dispatch reaching the server and no logs produced on either side.

Steps to reproduce:
1. Connect an MCP server whose tool schema includes outputSchema/execution (e.g. sequential-thinking ≥2025.11.25)
2. Attempt to invoke any tool from that server in Claude.ai chat
3. Observe the generic "Failed to call tool" error, with no server-side dispatch or logs

The same MCP server works correctly when called via Claude Code, indicating the issue is specific to the Claude.ai chat surface's tool-call handling, not the server itself.

Workaround: pinning the server to version 2025.7.1 resolves the issue, which points to the regression being tied to schema fields introduced in later versions.

### What did you expect to happen?

The tool call should dispatch to the server and either succeed or return a specific, diagnosable error — not fail generically with no logs on either side.

### Steps to reproduce

1. On Claude Desktop for macOS (1.24012.1), configure a stdio MCP server whose tool definition includes `outputSchema` and `execution` fields, e.g. in claude_desktop_config.json:

"seqthinking": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-sequential-thinking@2026.7.4"]
}

2. Restart the app. The server connects normally: `initialize` and `tools/list` succeed and appear in "paste of your computer".log; the tool is announced ("Connected to seqthinking (1 tools)").

3. In a Claude.ai chat conversation, ask Claude to call the tool (e.g. "Call sequentialthinking with thought='ok', thoughtNumber=1, totalThoughts=1, nextThoughtNeeded=false").

4. The call fails with a generic toast: _Failed to call tool "sequentialthinking"_. The web log records the approval gate passing (`approvalRequired:false`), but no `tools/call` ever reaches the server's stdio, the server log shows zero activity. Minimal payloads fail identically, ruling out size limits.

5. Change only the package version to 2025.7.1 (last version whose tool definition has only name/description/inputSchema, no outputSchema/execution) and restart: the same call now dispatches and succeeds (`tools/call` appears in the server log and returns a result).

### Area

MCP Connector (adding/managing servers)

### MCP Server (if applicable)

@modelcontextprotocol/server-sequential-thinking (stdio via npx; broken on 2025.11.25, 2025.12.18, 2026.7.4 — works on 2025.7.1)

### Error messages or logs

```shell
UI toast: Failed to call tool "sequentialthinking".

claude.ai-web.log (call passes the approval gate, then vanishes):
2026-07-22 13:25:00 [warn] [MCP] tool_approval_gate {"toolName":"seqthinking:sequentialthinking","approvalRequired":false,"hasBufferedInput":false}
2026-07-22 13:25:03 [warn] [MCP] tool_approval_gate {"toolName":"seqthinking:sequentialthinking","approvalRequired":false,"hasBufferedInput":false}

mcp-server-seqthinking.log during the same window (handshake only — the tools/call never arrives):
2026-07-22T16:18:30 [seqthinking] Message from client: method="initialize" id=0
2026-07-22T16:18:32 [seqthinking] Message from client: method="tools/list" id=1
(no further entries; no errors)

After pinning 2025.7.1 (only change), the exact same chat request works:
2026-07-22T16:34:40.431Z [seqthinking] Message from client: method="tools/call" id=2
2026-07-22T16:34:40.459Z [seqthinking] Message from server: id=2 result(1 blocks)
```

### Additional context

Environment: Claude Desktop 1.24012.1, macOS (Darwin 25.5.0), node/npx from Homebrew (/opt/homebrew/bin).

Tool definition diff between working and broken versions (from tools/list):
- 2025.7.1 (works): fields = [name, description, inputSchema]
- ≥2025.11.25 (broken): fields = [name, title, description, inputSchema, annotations, execution, outputSchema]
outputSchema carries "$schema": "http://json-schema.org/draft-07/schema#".

Ruled out during diagnosis:
- Server health: full initialize → tools/call cycle succeeds via raw stdio against every version tested; stdout is clean JSON-RPC.
- The same server+version (2026.7.4) works when called from Claude Code / local agent sessions on the same machine — only the Claude.ai chat surface fails.
- Payload size: a minimal call (thought="ok") fails identically.
- Also ruled out: config syntax, PATH inheritance, npx vs absolute binary path, server name with/without hyphen, permission/approval state (fails with approvalRequired both true and false), duplicate connectors, stale webview storage, app update (updater reports current).

Other stdio MCP servers with legacy-style tool definitions (context7, obsidian-vault, memory) work normally in the same chat conversations.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.