Built-in image_gen returns unrelated infographic outputs in Codex CLI session

Open 💬 2 comments Opened Jun 5, 2026 by liowald

What version of Codex CLI is running?

codex-cli 0.137.0

The same failure pattern also occurred yesterday in the same local project on codex-cli 0.136.0.

What subscription do you have?

Not surfaced by the CLI session.

Which model were you using?

gpt-5.5

What platform is your computer?

Darwin 25.5.0 arm64 arm

What terminal emulator and version are you using, if applicable?

Codex CLI in zsh; terminal emulator not captured in the session metadata.

Codex doctor report

Selected public-safe fields from codex doctor --json:

{
  "overallStatus": "warning",
  "codexVersion": "0.137.0",
  "model": "gpt-5.5",
  "modelProvider": "openai",
  "authConfigured": true,
  "storedApiKey": false,
  "networkProviderReachability": "ok",
  "websocketReachability": "Responses WebSocket handshake succeeded",
  "runtimePlatform": "macos-aarch64",
  "installMethod": "bun",
  "imageGenerationFeatureFlag": "enabled"
}

The full doctor report is available privately if needed.

What issue are you seeing?

During built-in image_gen usage from Codex CLI, the tool returned unrelated text-heavy educational infographics instead of the requested project image.

Current uploaded thread:

019e967f-a508-7b52-8b6c-27bafb1d23fd

Current task context:

  • Local project type: children’s picture-book art
  • Task: generate a children’s watercolor picture-book page
  • Requested content: South Pole scene with a penguin character, exactly three visible snowflakes, no baked-in text
  • Actual content returned on repeated retries: unrelated educational infographics with large text

The bad outputs were saved under the active thread’s generated-images folder, so this does not look like only a UI preview issue.

Current-thread affected outputs:

| File | Observed image content | Timestamp | Size | SHA-256 |
| --- | --- | --- | --- | --- |
| ig_01ff5442346ce0b6016a22925a90388191877efdf38fe80682.png | The Nitrogen Cycle infographic | 2026-06-05 11:13:14 | 1536x1024 | 7f0e89aa4fda3d702c0e86e65656e8e3e788ef5035dea4d25bd93827846a1af3 |
| ig_01ff5442346ce0b6016a22932c59308191b680d24bc1884585.png | From Cocoa Bean to Chocolate infographic | 2026-06-05 11:16:21 | 1536x1024 | e7d0ab16da3b7234ae2050bb3805259c07b7dd8afc3ceaddbe6a3bb1718132cd |
| ig_01ff5442346ce0b6016a2293ed90f08191a3c3d22db2ecea57.png | Renewable vs Non-Renewable Energy infographic | 2026-06-05 11:19:37 | 1536x1024 | 35969c3a02669f25fcb0fc1de767b919312ab12e0691c1d2818b3ade80d850c3 |

The same failure mode occurred yesterday in the same local project:

Prior affected session:

019e90b0-5301-77e2-a6fb-24cfda26ad5a

  • Date: 2026-06-04
  • Source: Codex CLI
  • CLI version: 0.136.0
  • Model: gpt-5.5
  • Task context: generate/revise children’s picture-book cover art, no text

Prior affected outputs:

| File | Observed image content | Timestamp | Size | SHA-256 |
| --- | --- | --- | --- | --- |
| ig_0cf58e470a9422c7016a21426c29c08191954aaba345a27a6e.png | Ischemic/Hemorrhagic Stroke infographic | 2026-06-04 11:19:37 | 1536x1024 | 2465acd2a3fdc529f119eb952620a0ab85298b84250ed9c07560ca2df59a075f |
| ig_0cf58e470a9422c7016a214539a5cc8191b36db6bddbc9e2ca.png | Qualities of a Good Leader infographic | 2026-06-04 11:31:03 | 1535x1024 | 7b993592ca6adfc7ac3616fdbae331c77eed6c5f4595c9bd0b45deceb06e7f0e |
| ig_0cf58e470a9422c7016a2145dac8688191ab25164c6ba53e6c.png | Poona Pact 1932 infographic | 2026-06-04 11:33:34 | 1536x1024 | 1765b0526581abf3417999efaf851cf5ca6648fc082cf5b6ff7cc28358606ec7 |

This looks related to, but distinct from, #22690 because this report is for Codex CLI on macOS and repeated across two CLI versions.

What steps can reproduce the bug?

No deterministic minimal repro yet. Observed sequence:

  1. Start a Codex CLI session in a local children’s picture-book art project.
  2. Use the built-in image_gen path through the $imagegen skill. Do not use the CLI/API fallback.
  3. Ask for project image generation with explicit visual constraints and no baked-in text.
  4. Retry after QA rejects a generated page-art candidate.
  5. Observe that subsequent image_gen calls return unrelated text-heavy educational infographics and save them into the active thread’s generated-images folder.

Full raw logs and image files are available privately if needed.

What is the expected behavior?

image_gen results should be associated with the active request/session/call only.

For these requests, Codex should return either:

  • a children’s watercolor picture-book image matching the active prompt, or
  • a clear generation error.

It should not attach unrelated generated image results from another topic, prompt, job, cache, or session.

Additional information

I checked prior local session history for the same project and found the same pattern on 2026-06-04, then saw it again in the current 2026-06-05 uploaded thread.

I did not include raw rollout JSONL because it contains unrelated conversation context and large generated-image payloads. The filenames, timestamps, dimensions, and SHA-256 hashes above should identify the affected events. I can provide the local logs or image files privately if helpful.

View original on GitHub ↗

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