Recurring loop: 'an image in the conversation could not be processed and was removed' burns all tokens
Bug summary
When an image (frequently a QR code) ends up in the conversation, every subsequent turn produces:
API Error: an image in the conversation could not be processed and was removed. Re-read the file with a different approach if you still need it.
The error repeats on every turn in a loop, rapidly consuming the entire token budget. The corrupted image stays in the thread history and re-contaminates each turn, so the only workaround is to abandon the chat and start a new one.
Environment
- Claude Code: VSCode native extension (Remote Control connected)
- Model: Opus 4.8 (1M context)
claude-opus-4-8[1m] - OS: Windows 11 Pro 10.0.26200
Steps to reproduce
- Have an image (e.g. a generated QR code) read into / appear in the conversation.
- Continue the conversation normally.
- Observe the "API Error: an image ... could not be processed and was removed" message returning on every turn.
Expected
The unprocessable image should be removed/stripped once, the turn should continue, and tokens should not keep being spent re-attempting it every turn.
Actual
The error loops indefinitely, the agent keeps "Processing...", and tokens are drained until the user manually interrupts and starts a fresh chat. Reported multiple times.
Impact
High — uncontrolled token consumption with no easy in-chat recovery
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗