claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[BUG] tool_use ids were found without tool_result blocks

Open mattmaslin opened this issue 7 months ago • 2 comments

Environment

  • Platform (select one):
    • [X ] Anthropic API
    • [ ] AWS Bedrock
    • [ ] Google Vertex AI
    • [ ] Other:
  • Claude CLI version: 1.0.24
  • Operating System: EndeavourOS
  • Terminal: allacritty

Bug Description

Using an MCP server for tracking tasks, Claude Code has become unusable and fails after making tool calls with and API Error and I cannot continue. It has blocked all work from moving forward with Claude code. ⎿ API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.5: tool_use ids were found without tool_result blocks immediately after: toolu_01A7FrFAeGZYCGMveVkXBMLd. Each tool_use block must have a corresponding tool_result block in the next message."}}

mattmaslin avatar Jun 16 '25 00:06 mattmaslin

I'm also seeing this, using Context7 and Playwright MCP. Have removed them now and not had the error again yet.

digitalmagnets avatar Jun 16 '25 14:06 digitalmagnets

Seems to be a repeated across multiple open issues now and is a huge roadblock. Rolling back to a previous version works.

mattmaslin avatar Jun 16 '25 20:06 mattmaslin

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.

github-actions[bot] avatar Sep 26 '25 14:09 github-actions[bot]