Bug Description
I get this error when I try to give a instruction:
API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.177: tool_use ids were found without tool_result blocks immediately after:
toolu_01FRgKKQqHgbYvCDuXPBAwnW. Each tool_use block must have a corresponding tool_result block in the next message."}}
Environment Info
- Platform: macos
- Terminal: vscode
- Version: 1.0.11
- Feedback ID: 9bc811ce-c2d8-47f1-b6d5-6ff137ae8b62
Errors
[{"error":"Error: Command failed: security find-generic-password -a $USER -w -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n at genericNodeError (node:internal/errors:983:15)\n at wrappedFn (node:internal/errors:537:14)\n at checkExecSyncError (node:child_process:882:11)\n at execSync (node:child_process:954:15)\n at JZ (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:683:2402)\n at file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:11763\n at Q (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:526:17069)\n at LU (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:10909)\n at HG (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:10355)\n at lO2 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2042:4758)","timestamp":"2025-06-04T18:49:44.700Z"},{"error":"Error: No logs found at /Users/raag/Library/Caches/claude-cli-nodejs/-Users-raag-Algo-trading/messages\n at tT4 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:583:3738)\n at iQ1 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:583:3487)\n at OAA.<anonymous> (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2337:2015)\n at async OAA.parseAsync (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:517:4184)\n at async vE5 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2340:5983)\n at async xE5 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2336:17530)","timestamp":"2025-06-04T18:49:44.721Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.177: `tool_use` ids were found without `tool_result` blocks immediately after: toolu_01FRgKKQqHgbYvCDuXPBAwnW. Each `tool_use` block must have a corresponding `tool_result` block in the next message.\"}}\n at Y5.generate (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1367:12578)\n at Jw.makeStatusError (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1382:2082)\n at Jw.makeRequest (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1382:5257)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async ve.showErrors (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:20326)\n at async ve (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:12078)\n at async bz2 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:20189)\n at async file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:16876\n at async Ro1 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:5204)\n at async fd (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:16846)","timestamp":"2025-06-04T18:50:00.064Z"}]
Bug Description
I get this error when I try to give a instruction:
API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.177:
tool_useids were found withouttool_resultblocks immediately after:toolu_01FRgKKQqHgbYvCDuXPBAwnW. Each
tool_useblock must have a correspondingtool_resultblock in the next message."}}Environment Info
Errors
[{"error":"Error: Command failed: security find-generic-password -a $USER -w -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n at genericNodeError (node:internal/errors:983:15)\n at wrappedFn (node:internal/errors:537:14)\n at checkExecSyncError (node:child_process:882:11)\n at execSync (node:child_process:954:15)\n at JZ (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:683:2402)\n at file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:11763\n at Q (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:526:17069)\n at LU (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:10909)\n at HG (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:10355)\n at lO2 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2042:4758)","timestamp":"2025-06-04T18:49:44.700Z"},{"error":"Error: No logs found at /Users/raag/Library/Caches/claude-cli-nodejs/-Users-raag-Algo-trading/messages\n at tT4 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:583:3738)\n at iQ1 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:583:3487)\n at OAA.<anonymous> (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2337:2015)\n at async OAA.parseAsync (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:517:4184)\n at async vE5 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2340:5983)\n at async xE5 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:2336:17530)","timestamp":"2025-06-04T18:49:44.721Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.177: `tool_use` ids were found without `tool_result` blocks immediately after: toolu_01FRgKKQqHgbYvCDuXPBAwnW. Each `tool_use` block must have a corresponding `tool_result` block in the next message.\"}}\n at Y5.generate (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1367:12578)\n at Jw.makeStatusError (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1382:2082)\n at Jw.makeRequest (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1382:5257)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async ve.showErrors (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:20326)\n at async ve (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:12078)\n at async bz2 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:20189)\n at async file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:16876\n at async Ro1 (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:5204)\n at async fd (file:///Users/raag/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1654:16846)","timestamp":"2025-06-04T18:50:00.064Z"}]