This is a repeated issue, when I press ESCAPE to interrupt Claude so that I can add another prompt to correct something it's doing wrong, often, i get this error after, and have to restart Claude when this happens.
It's pretty easy to reproduce... what else do you need to help isolate the issue?
Bug Description
⎿ API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.12: tool_use ids were found without
tool_result blocks immediately after: toolu_0177ZD9Sd6uNJc9HjvEQTrCR. Each tool_use block must have a corresponding
tool_result block in the next message."}}
Environment Info
- Platform: linux
- Terminal: vscode
- Version: 1.0.24
- Feedback ID: a873c78d-957e-43c3-b3e6-22011fe4355a
Errors
[{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.12: `tool_use` ids were found without `tool_result` blocks immediately after: toolu_0177ZD9Sd6uNJc9HjvEQTrCR. Each `tool_use` block must have a corresponding `tool_result` block in the next message.\"}}\n at h6.generate (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1329:12578)\n at Lw.makeStatusError (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:2082)\n at Lw.makeRequest (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:5257)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async ME2.K11.showErrors (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:22008)\n at async K11 (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:12203)\n at async ME2 (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:21854)\n at async file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17103\n at async yt1 (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:5151)\n at async Fu (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17073)","timestamp":"2025-06-17T02:11:25.872Z"},{"error":"Error: Request was aborted.\n at mo._createMessage (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1335:6810)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)","timestamp":"2025-06-17T02:11:29.691Z"}]
This is a repeated issue, when I press ESCAPE to interrupt Claude so that I can add another prompt to correct something it's doing wrong, often, i get this error after, and have to restart Claude when this happens.
It's pretty easy to reproduce... what else do you need to help isolate the issue?
Bug Description
⎿ API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.12:
tool_useids were found withouttool_resultblocks immediately after: toolu_0177ZD9Sd6uNJc9HjvEQTrCR. Eachtool_useblock must have a correspondingtool_resultblock in the next message."}}Environment Info
Errors
[{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.12: `tool_use` ids were found without `tool_result` blocks immediately after: toolu_0177ZD9Sd6uNJc9HjvEQTrCR. Each `tool_use` block must have a corresponding `tool_result` block in the next message.\"}}\n at h6.generate (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1329:12578)\n at Lw.makeStatusError (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:2082)\n at Lw.makeRequest (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:5257)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async ME2.K11.showErrors (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:22008)\n at async K11 (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:12203)\n at async ME2 (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:21854)\n at async file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17103\n at async yt1 (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:5151)\n at async Fu (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17073)","timestamp":"2025-06-17T02:11:25.872Z"},{"error":"Error: Request was aborted.\n at mo._createMessage (file:///home/danie/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1335:6810)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)","timestamp":"2025-06-17T02:11:29.691Z"}]