hangs after wrong image type for upload

Resolved 💬 3 comments Opened Oct 8, 2025 by Dexus Closed Nov 15, 2025
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

What version of Codex is running?

codex-cli 0.45.0

Which model were you using?

gpt-5

What platform is your computer?

Darwin 24.6.0 arm64 arm

What steps can reproduce the bug?

I have tried to mention 2 SVG files via @ after that was not working i tried the equivalent with PNG files. But it tries again and again the SVG files, that I tried before. That should not be done it should use the new files I provided...

What is the expected behavior?

Ignore wrong format image files, and not reuse the last message(s) with wrong image types.

What do you see instead?

⚠️ stream error: unexpected status 400 Bad Request: {
"error": {
"message": "The image data you provided does not represent a valid image. Please check your input and try again with one of the supported image formats: ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].",
"type": "invalid_request_error",
"param": "input",
"code": "invalid_value"
}
}; retrying 1/5 in 186ms…
⚠️ stream error: unexpected status 400 Bad Request: {
"error": {
"message": "The image data you provided does not represent a valid image. Please check your input and try again with one of the supported image formats: ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].",
"type": "invalid_request_error",
"param": "input",
"code": "invalid_value"
}
}; retrying 2/5 in 410ms…
⚠️ stream error: unexpected status 400 Bad Request: {
"error": {
"message": "The image data you provided does not represent a valid image. Please check your input and try again with one of the supported image formats: ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].",
"type": "invalid_request_error",
"param": "input",
"code": "invalid_value"
}
}; retrying 3/5 in 728ms…
⚠️ stream error: unexpected status 400 Bad Request: {
"error": {
"message": "The image data you provided does not represent a valid image. Please check your input and try again with one of the supported image formats: ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].",
"type": "invalid_request_error",
"param": "input",
"code": "invalid_value"
}
}; retrying 4/5 in 1.612s…
⚠️ stream error: unexpected status 400 Bad Request: {
"error": {
"message": "The image data you provided does not represent a valid image. Please check your input and try again with one of the supported image formats: ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].",
"type": "invalid_request_error",
"param": "input",
"code": "invalid_value"
}
}; retrying 5/5 in 3.107s…
■ unexpected status 400 Bad Request: {
"error": {
"message": "The image data you provided does not represent a valid image. Please check your input and try again with one of the supported image formats: ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].",
"type": "invalid_request_error",
"param": "input",
"code": "invalid_value"
}
}

Additional information

_No response_

View original on GitHub ↗

3 Comments

github-actions[bot] contributor · 10 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #4938
  • #4818
  • #4683

Powered by Codex Action

il13h · 10 months ago

I also met this bug with trying to use svg files. I found that exiting codex, editing the rollout file under .codex/sessions/, finding and deleting the line with the image upload data, then resuming resolves the "stuck" conversation.

etraut-openai contributor · 9 months ago

Closing in favor of #3835