File Upload Blocked: Unexpected Size Restriction Despite Image Being Under Limit

Resolved 💬 2 comments Opened Jun 13, 2025 by jlangvad Closed Nov 30, 2025

**Bug Description✱
Not able to proceed the chat because of the file size of an image, but the image was not exceeding 5 mb!

Environment Info

  • Platform: macos
  • Terminal: cursor
  • Version: 1.0.22
  • Feedback ID: 1c923637-cf88-418c-8fb6-cd6154bf7903

Errors

[{"error":"Error: Command failed: security find-generic-password -a $USER -w -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n    at checkExecSyncError (node:child_process:890:11)\n    at execSync (node:child_process:962:15)\n    at zZ (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:659:3921)\n    at file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:8871\n    at Q (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:526:17199)\n    at tJ (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:8017)\n    at XS (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:7098)\n    at O6 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:582:11210)\n    at hK1 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:5440)","timestamp":"2025-06-13T09:54:55.687Z"},{"error":"AbortError: The operation was aborted\n    at abortChildProcess (node:child_process:724:27)\n    at onAbortListener (node:child_process:794:7)\n    at process.processTicksAndRejections (node:internal/process/task_queues:77:11)","timestamp":"2025-06-13T09:55:01.230Z"},{"error":"Error: EISDIR: illegal operation on a directory, read\n    at Object.readSync (node:fs:744:3)\n    at tryReadSync (node:fs:444:20)\n    at Module.readFileSync (node:fs:490:19)\n    at Object.readFileSync (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:536:728)\n    at oxA (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:552:10516)\n    at Object.call (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1432:4500)\n    at call.next (<anonymous>)\n    at RY5 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1916:20930)\n    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n    at async nK1 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1916:19487)","timestamp":"2025-06-13T09:55:34.904Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.110.content.0.image.source.base64: image exceeds 5 MB maximum: 12350052 bytes > 5242880 bytes\"}}\n    at g6.generate (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1329:12578)\n    at Mw.makeStatusError (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:2082)\n    at Mw.makeRequest (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:5257)\n    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n    at async FE2.C11.showErrors (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:22008)\n    at async C11 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:12203)\n    at async FE2 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:21854)\n    at async file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:17103\n    at async Nt1 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:5151)\n    at async Yu (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:17073)","timestamp":"2025-06-13T10:58:07.230Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.110.content.0.image.source.base64: image exceeds 5 MB maximum: 12350052 bytes > 5242880 bytes\"}}\n    at g6.generate (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1329:12578)\n    at Mw.makeStatusError (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:2082)\n    at Mw.makeRequest (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:5257)\n    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n    at async FE2.C11.showErrors (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:22008)\n    at async C11 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:12203)\n    at async FE2 (file:///Users/jlangvad/.npm-global/lib/node_modules/@anthropic-ai/claude-code/cli.js:1700:21854)\n    at async file:///Users/jlangvad/.npm-global/lib/node_modules/@anthr

Note: Error logs were truncated.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗