Unable to upgrade codex with 'brew upgrade codex'
What version of Codex is running?
codex-cli 0.31.0
Which model were you using?
gpt-5
What platform is your computer?
Darwin 24.6.0 arm64 arm
What steps can reproduce the bug?
- Install codex using
brew install codex - As I launch codex, I get the nudge to upgrade on first open itself
jd@Kirans-MacBook-Pro vibe-code % codex
✨⬆️ Update available! 0.31.0 -> 0.32.0.
Run brew upgrade codex to update.
- When I do the upgrade with
brew upgrade codex, it says 0.31 is already installed
jd@Kirans-MacBook-Pro vibe-code % brew upgrade codex
Warning: codex 0.31.0 already installed
I have also tried brew upgrade [email protected] and met with Error: No available formula with the name "[email protected]".
What is the expected behavior?
- New install with brew should install the latest version and not ask for upgrade as soon as i install(unless a release was done right after I installed)
- When I get nudge to upgrade, the upgrade should work
What do you see instead?
No response
Additional information
No response
Same over here, seems the formula has not been updated yet and/or it takes some time for it to update.
https://formulae.brew.sh/formula/codex still shows 0.33.0 here although 0.34.0 is already out. One work around is to install it manually from https://github.com/openai/codex/releases which I had to do as 0.33 had issues with MCP servers.
It works now
brew upgrade codex
==> Upgrading 1 outdated package:
codex 0.31.0 -> 0.34.0
==> Fetching downloads for: codex
==> Fetching codex
==> Downloading https://ghcr.io/v2/homebrew/core/codex/blobs/sha256:8c9e4348837a8a918df875648ba753feccbb5a95a5dc80c038bffc715e0c0994
################################################################################################################################################################## 100.0%
==> Upgrading codex
0.31.0 -> 0.34.0
==> Pouring codex--0.34.0.arm64_sequoia.bottle.tar.gz
🍺 /opt/homebrew/Cellar/codex/0.34.0: 13 files, 17.5MB
==> Running `brew cleanup codex`...
Disable this behaviour by setting `HOMEBREW_NO_INSTALL_CLEANUP=1`.
Hide these hints with `HOMEBREW_NO_ENV_HINTS=1` (see `man brew`).
Removing: /opt/homebrew/Cellar/codex/0.31.0... (13 files, 17.9MB)
Removing: /Users/ouzy/Library/Caches/Homebrew/codex_bottle_manifest--0.31.0... (11.3KB)
Removing: /Users/ouzy/Library/Caches/Homebrew/codex--0.31.0... (7.8MB)
==> No outdated dependents to upgrade!
==> Caveats
zsh completions have been installed to:
/opt/homebrew/share/zsh/site-functions
I still have the issue, on version 0.31.0, using fish shell.
brew upgrade codex
Warning: codex 0.31.0 already installed
Edit: needed to update homebrew first: brew update to force brew to update its list of formulae, now it works.
Hey folks, did you brew update before?
yes, i had done that too. Nothing seemeed to work. So I did:
brew unlink codexbrew uninstall codex- and then
brew install codex
This fixed the issue but i think version 0.31 seems to somehow stuck in update avalilable loop without a way to install a new version. Before removing everything, I had tried brew update, brew install codex --HEAD
It works now
The problem seems to be upgrading from 0.31.0 specifically
Hey folks, did you
brew updatebefore?
Anyone running into this error like I did today when trying to update to 0.36 should do this!
Hey folks, did you
brew updatebefore?Anyone running into this error like I did today when trying to update to 0.36 should do this!
- brew update && brew upgrade
- brew install rust
- brew uninstall codex
- brew install codex --HEAD ========
Just did this and it worked: brew update && brew upgrade
Same issue form .46 -> .47.
% brew upgrade codex Warning: Treating codex as a cask. For the formula, specify the --formulaflag. To silence this message, use the--cask flag.
@captCovalent I was facing the same issue for this update.
It seems that you installed codex using a package manager (such as npm). Try uninstalling the version installed with npm or your package manager (npm uninstall -g @openai/codex)
Then try :
brew unlink codex
brew uninstall codex
and finally brew install codex
I tried it and it worked
For me, brew uninstall --cask codex worked!
It works now