[BUG] CC "Image cannot be empty" when pasting a copied selection of a CSV
Environment
- Platform (select one):
- [ ] Anthropic API
- [ ] AWS Bedrock
- [ ] Google Vertex AI
- [x] Other: Claude Code
- Claude CLI version: 1.0.85 (Claude Code)
- Operating System: MacOS 15.6
- Terminal: vscode terminal
Bug Description
When pasting a selection copied from a csv into CC, the pasted text appears briefly, and then gets truncated to "[Image #1]". Upon submitting the prompt, I receive "API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.150.co
ntent.0.image.source.base64: image cannot be empty"},"request_id":"req_011CSKg7yABsUTCZR9sW4QmP"}"
The issue persists in subsequent queries that do not include the selection, and it becomes impossible to continue the conversation, because every subsequent prompt receives that error. The error also occurs if the pasted text is removed from the prompt before sending.
No images were included anywhere in the conversation.
Steps to Reproduce
- Paste a copied selection from a csv opened in numbers on a mac into the CC terminal in VSCode
- Submit, or remove the pasted text and submit
- Submit additional queries without the pasted test
Expected Behavior
A normal response, i.e. not an error that falsely suggests an image was included in the prompt
Actual Behavior
I received the following error in this and all subsequent queries: API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.150.co
ntent.0.image.source.base64: image cannot be empty"},"request_id":"req_011CSKg7yABsUTCZR9sW4QmP"}
Additional Context
<img width="858" height="335" alt="Image" src="https://github.com/user-attachments/assets/8ffdb5a9-e53c-49eb-bae7-fe9a9c9334f4" />
13 Comments
Found 2 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
Having the same issue.
Same issue here.
After the issue happens, you need to start a new conversation since resuming that one keeps showing the same issue.
Having the same issue.
Just encountered same issue. As a side comment, in addition it would be nice to have a more clear way to 'skip/reset last command' when a fatal recurring issue like this happen so you don't have to start a new conversation.
Similar issue. Error dealing with a playright screenshot. Once it gets 400 error, can't resume conversation
same, it's really messed up, unable to recover at all
I was able to workaround somewhat by using /export conv.txt ; /clear; and then telling it to continue from conv.txt
This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.
This issue is still occurring for me
This issue has been automatically closed due to 60 days of inactivity. If you're still experiencing this issue, please open a new issue with updated information.
This issue was closed incorrectly despite recent human comments. This behavior of the bot is reported at https://github.com/anthropics/claude-code/issues/16497. Please upvote that issue, so maybe it gets noticed.
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.