Bug Report `tool_use` ids were found without `tool_result` blocks
Resolved 💬 2 comments Opened Aug 12, 2025 by BOFA1ex Closed Aug 13, 2025
Bug Description
Error: Error during compaction: Error: API Error: 400
{"type":"error","error":{"type":"invalid_request_error","message":"messages.135: tool_use ids were found
without tool_result blocks immediately after: toolu_01WNUbHpQy2RWWdoBF8JnF3r. Each tool_use block must
have a corresponding tool_result block in the next message."}}
Environment Info
- Platform: darwin
- Terminal: iTerm.app
- Version: 1.0.73
- Feedback ID:
Errors
[{"error":"Error: String not found in file. Failed to apply edit.\n at Mv (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1739:728)\n at mq0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1739:104)\n at Object.renderToolUseRejectedMessage (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1749:4116)\n at rSB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1933:2383)\n at MR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:330:19859)\n at fb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:42848)\n at vb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38369)\n at Vj (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38297)\n at cR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38151)\n at vK (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:35214)","timestamp":"2025-08-12T05:41:50.296Z"},{"error":"Error: Language not supported while highlighting code, falling back to markdown: \n at RX (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:1184)\n at file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:912\n at Array.map (<anonymous>)\n at YW (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:903)\n at TjB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2231:5231)\n at MR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:330:19859)\n at fb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:42848)\n at vb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38369)\n at Vj (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38297)\n at cR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38151)","timestamp":"2025-08-12T05:41:50.308Z"},{"error":"Error: String not found in file. Failed to apply edit.\n at Mv (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1739:728)\n at mq0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1739:104)\n at Object.renderToolUseRejectedMessage (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1749:4116)\n at rSB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1933:2383)\n at MR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:330:19859)\n at fb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:42848)\n at vb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38369)\n at Vj (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38297)\n at cR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38151)\n at vK (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:35214)","timestamp":"2025-08-12T05:41:50.314Z"},{"error":"Error: Language not supported while highlighting code, falling back to markdown: \n at RX (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:1184)\n at file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:912\n at Array.map (<anonymous>)\n at YW (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:903)\n at xjB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2231:8538)\n at MR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:330:19859)\n at fb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:42848)\n at vb (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38369)\n at Vj (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38297)\n at cR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:332:38151)","timestamp":"2025-08-12T05:41:50.315Z"},{"error":"Error: Language not supported while highlighting code, falling back to markdown: \n at RX (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:1184)\n at file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:912\n at Array.map (<anonymous>)\n at YW (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1685:903)\n at xjB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2231:8538)\n at MR (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:330:19859)\n at fb (file:///opt/homebrew/lib/node_modules/@anthropic-ai
Note: Error logs were truncated.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗