Codex Desktop flashes a console window when polling GitHub PRs via gh on Windows
Summary
On Windows, Codex Desktop periodically invokes the system-installed GitHub CLI (gh.exe) in the background to poll pull requests, and each invocation briefly flashes a black console window (a conhost.exe is created and immediately disappears). This is disruptive while working.
Environment
- Windows 11 (build 22000), 64-bit
- Codex Desktop
26.810.4967.0(process nameChatGPT.exe, packaged under WindowsApps) - GitHub CLI installed at
C:\Program Files\GitHub CLI\gh.exe - Codex also bundles its own
ghat~/.codex/tools/gh_2.96.0_windows_amd64/bin/gh.exe, but the app invokes the system-installed one
Repro
gh auth loginso GitHub is connected.- Launch Codex Desktop and leave it running.
- Within a few minutes, a console window flashes. A process monitor shows:
gh.exe pr list --head master --author @me --state all --json number,url,state,headRefName --repo <repo>- Parent process:
ChatGPT.exe(Codex Desktop) - Immediately followed by
conhost.execreation (the visible flashing window)
Expected behavior
Background gh invocations should never show a console window. Please launch them with CREATE_NO_WINDOW / hidden-window flags (or pipe output without allocating a console), and/or prefer the gh binary bundled with Codex so a separate system-wide install is not required.
Notes
The same class of issue affects other background console processes spawned by the app. For example, the CodexNotifyGuard scheduled task runs python.exe every 5 minutes with a visible console window; switching it to pythonw.exe (or hiding the window) fixes that one. Hiding console windows for background processes would avoid these flashes.
Thanks for looking into this!
1 Comment
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action