Windows: Codex auto-update causes first launch to run in background with no window (MainWindowHandle=0)
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.4k
- PR merge metrics
- PR metrics pending
Description
Environment
- OS: Windows
- Codex/ChatGPT desktop package:
OpenAI.Codex_26.825.5331.0_x64 - Codex CLI:
0.149.1
Problem
After Codex automatically downloaded and installed an update, clicking the Codex icon did not show any window.
Task Manager showed multiple ChatGPT/Codex processes running in the background.
PowerShell confirmed that all ChatGPT processes initially had:
MainWindowHandle = 0
The Codex CLI itself was working normally:
codex --version
codex-cli 0.149.1
CODEX_CLI_PATH was also valid and Test-Path returned True.
Observed behavior
- Codex automatically downloaded an update while the app was being used.
- After the update, clicking the Codex icon produced no visible window.
- Task Manager showed approximately 6 ChatGPT/Codex processes.
Get-ProcessshowedMainWindowHandle=0.- Leaving the processes running for several minutes eventually caused the Codex window to appear.
- After the window finally appeared, subsequent launches became normal.
- A controlled restart test showed the window being created successfully within approximately 10 seconds.
Example controlled test result:
10 sec | Process count: 8 | WindowHandle: 0, 0, 0, 0, 0, 1247092, 0, 0
Window created successfully, total time: 10 sec
Expected behavior
After an automatic update, Codex should open normally when clicking the application icon.
If post-update initialization or migration is required, the app should show a splash/loading/update screen rather than silently running multiple background processes with no visible window.
Additional notes
This appears to be related specifically to the first launch after an automatic desktop app update.
After waiting for the first launch to eventually complete, subsequent launches work normally.
No reinstall, cache deletion, or CLI repair was required.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the first launch after an automatic desktop update on Windows, using the reported package version and PowerShell checks for process count and MainWindowHandle. Trace the post-update initialization path and compare it with the controlled restart that creates a window within about 10 seconds. Done means the first post-update click reliably shows a window or visible loading state instead of multiple background processes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- desktop, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100