[BUG] Image reading - `(B.default || B) is not a function`
Status Closed — not planned
Maintainer reply ✓ Yes — dicksontsai
Activity 14 comments · opened Jul 8, 2025 · closed Jan 4, 2026
💡 Likely answer: A maintainer (dicksontsai, collaborator)
responded on this thread — see the highlighted reply below.
Environment
- Platform (select one):
- [x] Anthropic API
- [ ] AWS Bedrock
- [ ] Google Vertex AI
- [ ] Other: <!-- specify -->
- Claude CLI version: 1.0.44 (Claude Code)
- Operating System: macOS
- Terminal: iTerm2
Bug Description
I consistenly get this when trying to read images
⏺ Read(foo.png)
⎿ Error: (B.default || B) is not a function
14 Comments
Same issue. I came here to see if there were others. I thought it might be an Anthropic API hiccup but a re-request of the same files spit out the same thing:
Same setup as vemv:
This issue is due to an image processing dependency that did not get installed on your device. What kind of macOS chip are you running with?
We will introduce error handling so that Claude Code at least attempts to use the original image if the image processing dependency is missing.
I'm on an M3. From my hardware details section on my About This Mac:
I won't be able to until next week, but happy to try replicating the same scenario with
claude --debugwhen I'm back. Didn't occur to me in the moment.M2 Max here
Interesting, how did both of your install Claude Code? Did you use npm, bun, or some other method?
npm
same issue, I use npm install claude code, Is this issue only occurring on the Mac OS? my processor is Intel
I wonder if this is specific to intel macs. We do have a separate code path for that.
I'm on a M2 though, so there are reports for both architectures
Same issue. Macos apple silicon. Running in Fish shell if that's useful. Also why does it say the file doesn't exist using the @?
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 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 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.