[BUG] Claude Code stalls mid-task after announcing tool call, burning credits without writing output
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?
Claude Code repeatedly announces it is about to perform a long-running task (e.g., "writing the notebook now") but does not actually execute the tool call. The turn ends with only a short acknowledgement message, and the cycle repeats over multiple user prompts. No Write/Edit tool calls are ever emitted, so no file is produced, yet each round consumes tokens/credits.
Impact:
Wasted credits on turns that produce no work.
No error surfaced to the user — stall is silent, so the user cannot tell whether to retry, switch models, or report.
Suggested fixes / asks:
Detect "announced-but-unperformed" tool calls and surface a clear error instead of silently ending the turn.
Do not bill (or refund) turns that produce no tool calls and no substantive output when one was clearly promised.
Add a retry/timeout signal visible to the user when large Write payloads fail to serialize.
Additional context:
No partial file was ever created on disk.
What Should Happen?
The Write tool is invoked and the file is created in a single turn, or the model explains a concrete blocker.
Error Messages/Logs
API Error: Stream idle timeout - partial response received
Steps to Reproduce
Start a task that requires producing a large single-file artifact (e.g., a multi-section Jupyter notebook written via the Write tool in one call).
Ask the model to "write the notebook now."
Observe: model replies with a short sentence ("writing it now") but no tool call is emitted in the turn.
Prompt again. Same result.
Claude Model
Opus
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
claude-opus-4-7 (1M context)
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Other
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗