Executing local commands takes an inordinate amount of time
Resolved 💬 3 comments Opened Sep 17, 2025 by tvg-jpgxl Closed Jan 10, 2026
What version of Codex is running?
0.36.0
Which model were you using?
gpt-5-codex low
What platform is your computer?
Linux 6.14.0-110029-tuxedo x86_64 x86_64
What steps can reproduce the bug?
- Create a simple script
hi.shthat only contains the following command:echo "Hello, world!" - Make the scrip executable and assert that it completes correctly and instantly by running
./hi.shorbash ./hi.shorbash -lc ./hi.sh. - Start Codex in the same directory, give permission to execute.
- Prompt: "run hi.sh"
What is the expected behavior?
Codex executes the hi.sh script, which takes < 1 second, and reports that the output was "Hello, world!"
What do you see instead?
Codex apparently tries to execute the script, but it takes 60> seconds. The live status sometimes states "Preparing to run shell command" or "Executing <something>", but nothing happens.
The command completes after more than 60 seconds.
- Codex final answer: "Ran ./hi.sh → printed “Hello, world!” after a pyenv warning (pyenv: cannot rehash: /home/tvg/.pyenv/shims/.pyenv-shim exists). Script exited cleanly."
- The .pyenv-shim warning I've not seen before. I do have and use PyEnv, but not for Codex.
Additional information
Same problematic behavior occurs with medium and high reasoning efforts, and GPT-5.
I think it's safe to say that executing echo "Hello, world" should not take 60 seconds. I'm not sure how to troubleshoot this further; help is appreciated!
3 Comments
Could that be one of the reasons? https://x.com/thsottiaux/status/1967996885500928459 / (But they didn't make it dumber & reset the limits - https://x.com/sama/status/1968316161113882665 🎉)
I don't think so, since I noticed the same with GPT-5 (non-Codex), but perhaps their slowdowns apply to all GPT-5 models.
Just in case, I tried again today with GPT-5-minimal, but that's even worse. I'm also seeing more bash-related failures now:
or
Actually running the script does succeed, but again after 60 seconds:
Is there a way to get a more detailed view of what the tool is doing? The command timeout and command success both last ~60 seconds, so that tells me Codex is not capturing the exit but simply waiting for a timeout.
Identical to my issue here. https://github.com/openai/codex/issues/3891