Missing Tool Result Block for Tool Use in Conversation Resumption
Resolved 💬 1 comment Opened Jul 6, 2025 by yulin0629 Closed Jul 7, 2025
Bug Description
API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.19: tool_use ids were found without tool_result blocks immediately after:
toolu_01Nv8Pndnebmdr4cyQXA8ELG. Each tool_use block must have a corresponding tool_result block in the next message."}}
When I resume chat and make new request
Environment Info
- Platform: linux
- Terminal: windows-terminal
- Version: 1.0.43
- Feedback ID: 91cb41c0-ead0-47f3-aa9c-2d605df6fe9a
Errors
[{"error":"Error: Tool mcp__perplexity-ask__perplexity_ask not found\n at MS2 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1960:5596)\n at Ew (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:65:19798)\n at jP (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:42569)\n at SP (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:38118)\n at FL (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:38046)\n at xw (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:37900)\n at PW (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:34990)\n at h6 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:65:4822)\n at J3 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:32246)\n at A.Q.updateContainer (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:71:1835)","timestamp":"2025-07-06T16:47:06.610Z"},{"error":"Error: Tool mcp__perplexity-ask__perplexity_ask not found\n at MS2 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1960:5596)\n at Ew (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:65:19798)\n at jP (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:42569)\n at SP (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:38118)\n at FL (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:38046)\n at xw (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:37900)\n at PW (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:34990)\n at h6 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:65:4822)\n at J3 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:32246)\n at A.Q.updateContainer (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:71:1835)","timestamp":"2025-07-06T16:47:06.622Z"},{"error":"Error: Language not supported while highlighting code, falling back to markdown: \n at RF (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1491:1184)\n at file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1491:912\n at Array.map (<anonymous>)\n at WE (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1491:903)\n at RS2 (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1960:9737)\n at Ew (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:65:19798)\n at jP (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:42569)\n at SP (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:38118)\n at FL (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:38046)\n at xw (file:///home/yician/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:67:37900)","timestamp":"2025-07-06T16:47:06.625Z"}]This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗