CLI output & thinking order error, out of sequence & disordered
Resolved 💬 5 comments Opened Apr 20, 2026 by danche354 Closed Apr 22, 2026
💡 Likely answer: A maintainer (github-actions[bot], contributor)
responded on this thread — see the highlighted reply below.
What version of Codex CLI is running?
codex-cli 0.121.0
What subscription do you have?
custom
Which model were you using?
gpt5.4
What platform is your computer?
Darwin 25.3.0 arm64 arm
What terminal emulator and version are you using (if applicable)?
iterm2
What issue are you seeing?
The output and thinking content are interleaved.Is this incompatible with iTerm?As shown in the screenshot, it displays as output1 → thinking → output2.Moreover, output1 and output2 often contain large duplicate sections, as if the streaming output stream is messed up.
<img width="3264" height="890" alt="Image" src="https://github.com/user-attachments/assets/06158f39-b5ae-4437-adf5-51ca96863006" />
sometimes the tokens output as following, ‘AB’ is repeated
---
A
B
thinking
A
B
C
What steps can reproduce the bug?
just ask any question
What is the expected behavior?
_No response_
Additional information
_No response_
5 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
If you're able to repro this, please use
/feedbackto upload logs and session details, then include the thread ID below.Do you have any non-default config settings specified in your config.toml file?
no custom settings. you can check this '019da965-27d7-7c72-b576-00e42ea186b2'
Thanks for uploading the logs. Based on my reading of your logs, you have a custom model provider configured. It's likely the cause of the out-of-order reasoning-summary events.
I'm going to close the issue, but if you're able to repro when using the standard OpenAI responses endpoint and provider, let me know and I'll investigate further.