gpt-5.1-codex-max made several bad decisions one after another, ending with the deletion of the file
Resolved 💬 3 comments Opened Nov 20, 2025 by guidedways Closed Nov 20, 2025
💡 Likely answer: A maintainer (github-actions[bot], contributor)
responded on this thread — see the highlighted reply below.
What version of Codex is running?
0.61.0-alpha.3
What subscription do you have?
Pro
Which model were you using?
gpt-5.1-codex-max ExHigh
What platform is your computer?
macOS
What issue are you seeing?
From the beginning Codex just kept making poor decisions, I had to constantly steer it to _do better_ (in terms of architecture) and in the end when it was nearly there, it deleted the entire file because it felt it had made too many continuous edits one after another.
What steps can reproduce the bug?
Uploaded thread: 019aa00a-7f6b-7aa2-a48f-6de2276df170
What is the expected behavior?
Never, ever, ever, ever, ever, ever, ever delete a file when not asked. Never git checkout (I've instructed clearly in AGENTS.md) - any time codex feels it's working for too long or making too many repeated edits, it ends up giving up and destroying all that hard work.
Additional information
_No response_
3 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
Thanks for the bug report. We'll share the feedback with the team responsible for training our codex models. We're tracking this feedback and similar reports so we can make future models more robust and efficient. And thanks for using the
/feedbackcommand. That additional information is useful.I've noticed this occurs a lot more often when the context window hits 44-35%. You'll ask it to make an innocuous edit, and it'll completely delete the file. You stop it and ask it wtf it was doing and all it can do is apologize. Further supporting this might be a context issue, is codex then tries to reconstruct the file only to yield a file several times shorter (654 lines to ~160). Is this related to the automatic compaction, missing in the middle, or some other behavior? It's very, very frustrating and I've had it happen a handful of times already.
Mine is in v0.63.0, wsl 2.0 on Debian 12. Windows 10.