Getting Error while using Sonnet - 4.6 in copilot
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Error: (query) Execution failed: CAPIError: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.64: tool_use ids were found without tool_result blocks immediately after: toolu_vrtx_01DKnVMfHy5NjqGjXp7V4RLY. Each tool_use block must have a corresponding tool_result block in the next message."},"request_id":"req_vrtx_011CbYQPWTCfSAnGJSQ4k32V"} (Request ID: 7F75:160510:27CFAC7:2D5370B:6A1A99A0)
What Should Happen?
i am trying to find solution.....still getting the error
Error Messages/Logs
Steps to Reproduce
how can we correct the issue?
Copilot CLI
Error: (query) Execution failed: CAPIError: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.64: tool_use ids were found without tool_result blocks immediately after: toolu_vrtx_01DKnVMfHy5NjqGjXp7V4RLY. Each tool_use block must have a corresponding tool_result block in the next message."},"request_id":"req_vrtx_011CbYQPWTCfSAnGJSQ4k32V"} (Request ID: [7F75:160510:27CFAC7:2D5370B:6A1A99A0)....[](url)](
<img width="1337" height="715" alt="Image" src="https://github.com/user-attachments/assets/4659935a-b4fe-41ad-b003-124ba0f77f00" />
)
Claude Model
Sonnet (default)
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
Sonnet 4.6
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Terminal.app (macOS)
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗