codex - 💡(How to fix) Fix Built-in image_gen returns unrelated infographic outputs in Codex CLI session

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

  • a clear generation error.

Root Cause

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

Code Example

{
  "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"
}
RAW_BUFFERClick to expand / collapse

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:

FileObserved image contentTimestampSizeSHA-256
ig_01ff5442346ce0b6016a22925a90388191877efdf38fe80682.pngThe Nitrogen Cycle infographic2026-06-05 11:13:141536x10247f0e89aa4fda3d702c0e86e65656e8e3e788ef5035dea4d25bd93827846a1af3
ig_01ff5442346ce0b6016a22932c59308191b680d24bc1884585.pngFrom Cocoa Bean to Chocolate infographic2026-06-05 11:16:211536x1024e7d0ab16da3b7234ae2050bb3805259c07b7dd8afc3ceaddbe6a3bb1718132cd
ig_01ff5442346ce0b6016a2293ed90f08191a3c3d22db2ecea57.pngRenewable vs Non-Renewable Energy infographic2026-06-05 11:19:371536x102435969c3a02669f25fcb0fc1de767b919312ab12e0691c1d2818b3ade80d850c3

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:

FileObserved image contentTimestampSizeSHA-256
ig_0cf58e470a9422c7016a21426c29c08191954aaba345a27a6e.pngIschemic/Hemorrhagic Stroke infographic2026-06-04 11:19:371536x10242465acd2a3fdc529f119eb952620a0ab85298b84250ed9c07560ca2df59a075f
ig_0cf58e470a9422c7016a214539a5cc8191b36db6bddbc9e2ca.pngQualities of a Good Leader infographic2026-06-04 11:31:031535x10247b993592ca6adfc7ac3616fdbae331c77eed6c5f4595c9bd0b45deceb06e7f0e
ig_0cf58e470a9422c7016a2145dac8688191ab25164c6ba53e6c.pngPoona Pact 1932 infographic2026-06-04 11:33:341536x10241765b0526581abf3417999efaf851cf5ca6648fc082cf5b6ff7cc28358606ec7

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.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING