Codex exec terminates after making a plan (only when using gpt-5-codex)

Resolved 💬 3 comments Opened Oct 4, 2025 by alex-lawlab Closed Jan 10, 2026
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

What version of Codex is running?

codex 0.44.0

Which model were you using?

gpt-5-codex

What platform is your computer?

Linux 6.1.153-175.280.amzn2023.x86_64 x86_64 x86_64

What steps can reproduce the bug?

  1. Set no sandbox and full auto mode.
  2. Go to any repository.
  3. Use codex exec to just modify some files. E.g.
codex exec "Can you modify some files so that I can test your capabilities, any modifications are fine"

What is the expected behavior?

Codex modify some files and then quits.

What do you see instead?

Codex starts running, makes a plan, and then just quits. No file has been modified.

Sample logs:


Can you modify some files so that I can test
▌ your capabilities, any modifications are fine

> Plan

  - Update scripts/copy_file.py to accept CLI
  arguments plus simple safeguards.
  - Extend scripts/move_file.py with a dry-run
  option and better error handling.
  - Improve scripts/list_files.sh by adding
  filtering/sorting switches, then note the
  changes in README.md.

Additional information

Sometimes it works fine but a lot of times (2/3 times) it triggers this issue. Using the original gpt-5 does not trigger the issue. It only happens with the new gpt-5-codex model and only when using codex exec.

When it happens there is no errors or warnings displayed. Just normal exits.

Original issue is: https://github.com/openai/codex/issues/3912#issuecomment-3367982708

I closed it as I thought it was due to my prompt. But recently it came back again, but I cannot reopen the original issue.

View original on GitHub ↗

3 Comments

github-actions[bot] contributor · 10 months ago

Potential duplicates detected:

  • #3912

Powered by Codex Action

cawmit · 10 months ago

@alex-lawlab You closed the first issue, this issue was closed because it was marked as a duplicate if your first issue :D

I've been working in CI with codex CLI and have extensively experienced this bug. Trying to fix it for now by improving prompt format

etraut-openai contributor · 7 months ago

Closing old bugs.