You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reposting since these have gone quiet. On Windows, Orca's main process is GUI-subsystem and owns no console, so every console-subsystem child it spawns (ssh.exe, agent-browser-win32-x64.exe, powershell.exe) gets a brand-new visible conhost. It flashes on screen and takes foreground — keystrokes typed into an Orca terminal at that moment go into the black box instead. Fix is windowsHide: true at each spawn site, matching the idiom already used across src/main/ssh/.
PR 1 — SSH spawn sites:#10497
Covers the ssh -G config probe, the ProxyJump ssh -W tunnel, and the ProxyCommand cmd.exe wrapper. 4 files, +38/-3. Closes #10488.
PR 2 — agent-browser spawn sites:#10636
Covers the agent-browser binary spawn and the previously-uncovered DPAPI cookie-import PowerShell spawn. 4 files, +59/-2.
Both are small, independent, and non-draft. Both have tests that fail on main and pass on the branch, plus a real Windows 11 capture showing GetConsoleWindow() go from a visible handle to 0 under the flag — and a check that the shell: true / .cmd-shim caveat (where windowsHide is a silent no-op) doesn't apply to either path.
Last activity on both was Aug 10, no review decision yet. Anything I can do to help move them?
Info from a local code read at main — not asking for anything, just leaving what I found while triaging, in case it saves someone a step.
The three spawn families named in this repost look covered at HEAD. src/shared/child-process/spawn-resolution.ts:34 sets windowsHide: true unconditionally for the shared spawn path, and src/shared/child-process/run-process.ts:52 routes spawnProcess / runProcess / runProcessSync through it:
That landed in #17869 (c252d855ac, 2026-09-05) and first shipped in v1.4.199. One thing that may matter for the two PRs this repost is waiting on: #10497 and #10636 were both closed unmerged on 2026-08-15, so as far as I can tell they are superseded rather than pending review. If windows-console-visibility.test.ts does not already pin the same spawn sites, their test cases might still be worth salvaging.
Residual I did not chase: forks that do not go through the shared helper — src/main/daemon/daemon-init.ts and src/main/plugins/plugin-host-process.ts are still listed in src/shared/child-process/__fixtures__/windows-console-visibility-allowlist.txt.
Confirming the residual @mmarabel flagged — src/main/daemon/daemon-init.ts is reproducible on a current install, and it's the highest-volume offender I could measure.
Environment: Orca 1.4.207, Windows 11, no WSL.
Repro: Open any project in Orca and start an agent (codex) in a terminal. A black console window appears roughly every 2 seconds and closes immediately.
Measured: 81 powershell.exe spawns in 3 minutes (~1 per 2.2s), all from the daemon process:
That is the Windows process-table scan used for agent session tracking.
Why it only shows up sometimes: the scan appears to run while an agent session is active. With Orca open but no agent running I measured 0 spawns over 20s; the moment a codex session starts it goes to roughly one every 2 seconds.
Two related notes:
This spawn does not go through src/shared/child-process/spawn-resolution.ts, so it does not inherit the unconditional windowsHide: true that fixed the ssh / agent-browser families.
There is a second visible window on agent launch: Orca runs
cmd.exe /K "chcp 65001 > nul & if defined ORCA_CODEX_LAUNCH_PREFLIGHT call %ORCA_CODEX_LAUNCH_PREFLIGHT_CMD_QUOTE%%ORCA_CODEX_LAUNCH_PREFLIGHT%%ORCA_CODEX_LAUNCH_PREFLIGHT_CMD_QUOTE% agent hooks prepare-codex > nul 2>&1"
which is also spawned un-hidden. Note the shell: true / .cmd-shim caveat from the original report applies here — windowsHide may be a no-op for the cmd.exe path, so it may need the Invoke-CimMethod Win32_Process Create route or similar.
Happy to test a patch against this path if someone points me at a branch.
Separate from the flashing issue, and in my experience more severe: closing Orca leaks the daemon and the running agent session, and the orphaned session keeps firing the Orca agent hooks indefinitely. Console windows keep appearing and never stop.
Repro (Windows 11, Orca 1.4.207, no WSL):
Open a project in Orca and start an agent (codex) in a terminal.
Close Orca.
Observe: powershell.exe windows keep appearing every few seconds, indefinitely.
Measured: with Orca already closed, 8 powershell.exe spawns in a 15-second sample, and the count was still climbing — hundreds had accumulated by the time I killed it by hand. It did not stop on its own.
Related: the hooks look registered twice per event. In Orca's managed codex home (%APPDATA%\orca\codex-runtime-home\home\hooks.json) every event lists two Orca hook scripts:
The same pair repeats for PermissionRequest, PostToolUse, PostCompact, SessionStart, UserPromptSubmit, SubagentStart, SubagentStop and Stop. That doubles the consoles spawned per event. The user-level ~/.codex/hooks.json has only one entry per event, so this looks like a duplicate or legacy entry that a reconcile pass isn't removing.
Impact: after Orca exits, the leaked session keeps hitting a hook endpoint that no longer exists, and it never self-terminates. Fixing windowsHide would hide the flash but would not fix the leak — the orphaned process and the duplicated hook registrations are worth addressing on their own.
Workaround: manually kill the Orca.exe under AppData\Local\Orca\daemon-host\ and the codex.exe under AppData\Roaming\orca\codex-runtime-home\.
Hitting this too on Windows 11, Orca 1.4.212. Confirmed via process tracing (Get-CimInstance Win32_Process on the flashed cmd.exe/conhost.exe, walking ParentProcessId) that the visible console is spawned under Orca's daemon-host process tree, matching the "console-subsystem child gets a brand-new visible conhost" pattern described above.
One additional data point that might be relevant: app.asar ships a vendored/patched node-pty@1.1.0 with two custom patch files — node-pty-1.1.0-console-list-agent-patch.cjs and node-pty-1.1.0-windows-pty-teardown-patch.cjs. All the regular spawn/execFile/fork call sites I could find in app.asar do set windowsHide: true correctly, so the gap seems narrower than "windowsHide missing everywhere" — consistent with this issue's specific spawn sites (ssh/agent-browser/powershell) rather than a systemic problem. Flagging the node-pty patches here in case the PTY create/teardown path is a separate/additional source of the same symptom worth covering in the same pass.
+1 for getting #10497 and #10636 reviewed — both look like clean, well-tested fixes for the exact spawn sites causing this.
Additional reproduction details from my Windows setup:
Active agent: Grok. A console window flashes repeatedly and steals focus when Grok runs commands/tools.
Orca daemon-host version observed in the process trace: 1.4.215.
Codex desktop installed on the same PC: 26.924.22138 (build 11645, production channel). This is the desktop app version, not a measured Codex CLI version; Codex was not the active agent for this reproduction.
The ProcMon capture includes an Orca grok-hook.cmd invocation and many conhost.exe starts. It does not record foreground-window changes, so I cannot attribute every individual flash to one spawn site.
Status update from the Orca team, for everyone watching this issue.
What's causing the windows we can still reproduce. Since Codex 0.156, the first codex you open starts a shared background server, and later Codex sessions connect to it. On Windows that server runs without a console of its own, so every command it runs for Codex (the shell tool, git, and agent hooks) gets a brand-new visible terminal window, which also takes keyboard focus. On a Windows 11 test machine, one short Codex turn attached to that server opened 23 windows in about 10 seconds. This is Codex's own process launching, tracked upstream at openai/codex#44768.
What's changing in the next release (1.4.217). Orca now starts Codex in its terminals with --no-daemon (#23900), so each Codex tab runs its own server inside the terminal and those commands stay hidden. On the release candidate, Codex opened no windows in PowerShell and Git Bash terminals.
Not covered yet: Command Prompt (cmd.exe) terminals. The launch change is added through each shell's startup, and cmd.exe doesn't have that hook yet, so Codex in a Command Prompt tab still connects to the shared server and still flashes windows. Until that's fixed, switching the terminal shell to PowerShell or Git Bash avoids it. We're looking at covering Command Prompt next.
When we expect the rest to be fixed. Codex has fixed this on its side: its background server now starts those commands hidden (openai/codex#48483, openai/codex#49164 and openai/codex#49308, merged September 26–29). Codex 0.159.0 only has part of that, and it still opens windows (confirmed by another user in openai/codex#44768). The complete fix is in the 0.160 and 0.161 prereleases, so we expect the first stable Codex release after 0.159.0 to stop the windows in every terminal, Command Prompt included. After updating Codex, close all Codex sessions once so its background server restarts on the new version. We'll confirm here once that release is out and we've re-tested it.
After Orca quits, the terminal daemon deliberately keeps your terminals, and any agent in them, running so they're still there when you reopen Orca. An agent left running keeps running its hooks. With the change above those no longer open windows, but the process keeps running until you close that terminal.
with the spawn being the Get-CimInstance -ClassName Win32_Process ... | ConvertTo-Json scan. So #15749 is working here.
2. This install falls in the "Command Prompt not covered" bucket.
Orca launches Codex tabs here through cmd.exe (3 such processes observed simultaneously):
cmd.exe /K "chcp 65001 > nul & if defined ORCA_CODEX_LAUNCH_PREFLIGHT call %ORCA_CODEX_LAUNCH_PREFLIGHT_CMD_QUOTE%%ORCA_CODEX_LAUNCH_PREFLIGHT%%ORCA_CODEX_LAUNCH_PREFLIGHT_CMD_QUOTE% agent hooks prepare-codex > nul 2>&1"
So the --no-daemon change in 1.4.217 will not change anything for this configuration — the fix here has to come from the Codex 0.160+ release, as the status update describes. Worth knowing that the "switch your terminal shell to PowerShell or Git Bash" workaround is not just a niche case: this is a default-looking setup.
3. Minor, possibly related — a separate spawn at Codex launch.
The same cmd.exe /K "... agent hooks prepare-codex ..." line above is itself spawned by Orca.exe at Codex launch (visible in the process trace alongside the Codex background server spawns). I did not confirm whether it renders a visible window, so I am flagging it only in case it is a second spawn site on the same path. If it is already covered, please ignore.
Thanks for the detailed status update — the breakdown of what is fixed vs. pending was easy to follow.
Quick clarification for the original report: the ssh, agent-browser and cookie-import windows from the first post were fixed on Orca's side in #15746 and #15887 (both shipped in 1.4.190). Those replaced #10497 and #10636. The Codex windows discussed later in the thread are the ones fixed upstream in Codex 0.159.2.
If you still see windows on current Orca, with your Codex background server on 0.159.2 or later, please open a new issue with your Orca and agent versions. That especially applies to Grok, which we weren't able to verify. @LotusRenge, we couldn't reproduce the duplicate claude-hook.cmd entry in Orca's managed Codex home. If you still have it, a new issue with your %APPDATA%\orca\codex-runtime-home\home\hooks.json would help. The daemon keeping terminals (and agents in them) running after Orca closes is intentional, so they're still there when you reopen Orca.
Activity
mmarabel commentedon Sep 15, 2026
Info from a local code read at
main— not asking for anything, just leaving what I found while triaging, in case it saves someone a step.The three spawn families named in this repost look covered at HEAD.
src/shared/child-process/spawn-resolution.ts:34setswindowsHide: trueunconditionally for the shared spawn path, andsrc/shared/child-process/run-process.ts:52routesspawnProcess/runProcess/runProcessSyncthrough it:system-ssh-command.ts:46,68,system-ssh-forward-process.ts:55,system-ssh-file-transfer.ts:61,69,system-ssh-dynamic-forward-process.ts:42,ssh-proxy-command.ts:123agent-browser-bridge-execution.ts:215,agent-browser-bridge-raw-process.ts:34,orcad/external-chromium-browser-session.ts:168browser-cookie-key.ts:146(viarunProcessSync)That landed in #17869 (
c252d855ac, 2026-09-05) and first shipped in v1.4.199. One thing that may matter for the two PRs this repost is waiting on: #10497 and #10636 were both closed unmerged on 2026-08-15, so as far as I can tell they are superseded rather than pending review. Ifwindows-console-visibility.test.tsdoes not already pin the same spawn sites, their test cases might still be worth salvaging.Residual I did not chase: forks that do not go through the shared helper —
src/main/daemon/daemon-init.tsandsrc/main/plugins/plugin-host-process.tsare still listed insrc/shared/child-process/__fixtures__/windows-console-visibility-allowlist.txt.AmethystLiang commentedon Sep 16, 2026
Thanks! PR #10497 is in review to resolve conhost flashing and focus stealing on Windows.
LotusRenge commentedon Sep 23, 2026
Confirming the residual @mmarabel flagged —
src/main/daemon/daemon-init.tsis reproducible on a current install, and it's the highest-volume offender I could measure.Environment: Orca 1.4.207, Windows 11, no WSL.
Repro: Open any project in Orca and start an agent (codex) in a terminal. A black console window appears roughly every 2 seconds and closes immediately.
Measured: 81
powershell.exespawns in 3 minutes (~1 per 2.2s), all from the daemon process:Spawn:
That is the Windows process-table scan used for agent session tracking.
Why it only shows up sometimes: the scan appears to run while an agent session is active. With Orca open but no agent running I measured 0 spawns over 20s; the moment a codex session starts it goes to roughly one every 2 seconds.
Two related notes:
This spawn does not go through
src/shared/child-process/spawn-resolution.ts, so it does not inherit the unconditionalwindowsHide: truethat fixed the ssh / agent-browser families.There is a second visible window on agent launch: Orca runs
which is also spawned un-hidden. Note the
shell: true/.cmd-shim caveat from the original report applies here —windowsHidemay be a no-op for thecmd.exepath, so it may need theInvoke-CimMethod Win32_Process Createroute or similar.Happy to test a patch against this path if someone points me at a branch.
LotusRenge commentedon Sep 23, 2026
Separate from the flashing issue, and in my experience more severe: closing Orca leaks the daemon and the running agent session, and the orphaned session keeps firing the Orca agent hooks indefinitely. Console windows keep appearing and never stop.
Repro (Windows 11, Orca 1.4.207, no WSL):
powershell.exewindows keep appearing every few seconds, indefinitely.Measured: with Orca already closed, 8
powershell.exespawns in a 15-second sample, and the count was still climbing — hundreds had accumulated by the time I killed it by hand. It did not stop on its own.Orphans left behind after the UI exited:
Both remained after the main
Orca.exe(and its crashpad handler) were gone.What the orphaned codex spawns (both parented by PID 9740):
Related: the hooks look registered twice per event. In Orca's managed codex home (
%APPDATA%\orca\codex-runtime-home\home\hooks.json) every event lists two Orca hook scripts:The same pair repeats for PermissionRequest, PostToolUse, PostCompact, SessionStart, UserPromptSubmit, SubagentStart, SubagentStop and Stop. That doubles the consoles spawned per event. The user-level
~/.codex/hooks.jsonhas only one entry per event, so this looks like a duplicate or legacy entry that a reconcile pass isn't removing.Impact: after Orca exits, the leaked session keeps hitting a hook endpoint that no longer exists, and it never self-terminates. Fixing
windowsHidewould hide the flash but would not fix the leak — the orphaned process and the duplicated hook registrations are worth addressing on their own.Workaround: manually kill the
Orca.exeunderAppData\Local\Orca\daemon-host\and thecodex.exeunderAppData\Roaming\orca\codex-runtime-home\.wwenrr commentedon Sep 26, 2026
Hitting this too on Windows 11, Orca 1.4.212. Confirmed via process tracing (
Get-CimInstance Win32_Processon the flashedcmd.exe/conhost.exe, walkingParentProcessId) that the visible console is spawned under Orca'sdaemon-hostprocess tree, matching the "console-subsystem child gets a brand-new visible conhost" pattern described above.One additional data point that might be relevant:
app.asarships a vendored/patchednode-pty@1.1.0with two custom patch files —node-pty-1.1.0-console-list-agent-patch.cjsandnode-pty-1.1.0-windows-pty-teardown-patch.cjs. All the regularspawn/execFile/forkcall sites I could find inapp.asardo setwindowsHide: truecorrectly, so the gap seems narrower than "windowsHide missing everywhere" — consistent with this issue's specific spawn sites (ssh/agent-browser/powershell) rather than a systemic problem. Flagging the node-pty patches here in case the PTY create/teardown path is a separate/additional source of the same symptom worth covering in the same pass.+1 for getting #10497 and #10636 reviewed — both look like clean, well-tested fixes for the exact spawn sites causing this.
AmethystLiang commentedon Sep 29, 2026
Thanks for the debug info. Will get this resolved in the next release.
spock-wen commentedon Sep 29, 2026
Additional reproduction details from my Windows setup:
The ProcMon capture includes an Orca
grok-hook.cmdinvocation and manyconhost.exestarts. It does not record foreground-window changes, so I cannot attribute every individual flash to one spawn site.brennanb2025 commentedon Sep 29, 2026
Status update from the Orca team, for everyone watching this issue.
What's causing the windows we can still reproduce. Since Codex 0.156, the first
codexyou open starts a shared background server, and later Codex sessions connect to it. On Windows that server runs without a console of its own, so every command it runs for Codex (the shell tool,git, and agent hooks) gets a brand-new visible terminal window, which also takes keyboard focus. On a Windows 11 test machine, one short Codex turn attached to that server opened 23 windows in about 10 seconds. This is Codex's own process launching, tracked upstream at openai/codex#44768.What's changing in the next release (1.4.217). Orca now starts Codex in its terminals with
--no-daemon(#23900), so each Codex tab runs its own server inside the terminal and those commands stay hidden. On the release candidate, Codex opened no windows in PowerShell and Git Bash terminals.Not covered yet: Command Prompt (
cmd.exe) terminals. The launch change is added through each shell's startup, andcmd.exedoesn't have that hook yet, so Codex in a Command Prompt tab still connects to the shared server and still flashes windows. Until that's fixed, switching the terminal shell to PowerShell or Git Bash avoids it. We're looking at covering Command Prompt next.When we expect the rest to be fixed. Codex has fixed this on its side: its background server now starts those commands hidden (openai/codex#48483, openai/codex#49164 and openai/codex#49308, merged September 26–29). Codex 0.159.0 only has part of that, and it still opens windows (confirmed by another user in openai/codex#44768). The complete fix is in the 0.160 and 0.161 prereleases, so we expect the first stable Codex release after 0.159.0 to stop the windows in every terminal, Command Prompt included. After updating Codex, close all Codex sessions once so its background server restarts on the new version. We'll confirm here once that release is out and we've re-tested it.
Other sources reported in this thread:
ssh, agent-browser and cookie-import spawns were fixed in fix(windows): one chokepoint for every child process #15746 and fix(win32): hide the console window for agent-browser and git helpers #15887 (both shipped in 1.4.190). The terminal daemon's PowerShell process scan every few seconds is gone as of 1.4.217 (fix(windows): preserve relocated terminals and native process scans #22872): the daemon now reads the process list in-process. A daemon started by an older version keeps scanning until its terminals are closed. On the test machine an idle Orca, and Claude Code running commands in an Orca terminal, opened no windows.We'll update here when Command Prompt is covered.
LotusRenge commentedon Sep 30, 2026
Independent verification on a real user environment (Orca 1.4.209, Windows 11, no WSL), plus one data point relevant to the cmd.exe gap.
1. The daemon PowerShell process-table scan is gone — confirmed.
Measured 0
powershell.exeprocess-table scans in a 60-second window.For comparison, on 1.4.207 this same install produced 81 spawns in a 3-minute window (~1 every 2.2s), all parented by:
with the spawn being the
Get-CimInstance -ClassName Win32_Process ... | ConvertTo-Jsonscan. So #15749 is working here.2. This install falls in the "Command Prompt not covered" bucket.
Orca launches Codex tabs here through
cmd.exe(3 such processes observed simultaneously):So the
--no-daemonchange in 1.4.217 will not change anything for this configuration — the fix here has to come from the Codex 0.160+ release, as the status update describes. Worth knowing that the "switch your terminal shell to PowerShell or Git Bash" workaround is not just a niche case: this is a default-looking setup.3. Minor, possibly related — a separate spawn at Codex launch.
The same
cmd.exe /K "... agent hooks prepare-codex ..."line above is itself spawned by Orca.exe at Codex launch (visible in the process trace alongside the Codex background server spawns). I did not confirm whether it renders a visible window, so I am flagging it only in case it is a second spawn site on the same path. If it is already covered, please ignore.Thanks for the detailed status update — the breakdown of what is fixed vs. pending was easy to follow.
AmethystLiang commentedon Sep 30, 2026
This seems to be a codex CLI upstream issue openai/codex#48074, openai/codex#44768
Fixes from Codex CLI are supposed to land in their next 1-2 versions
brennanb2025 commentedon Sep 30, 2026
Hey all, good news, they fixed this upstream.
As they said in the post, you'll need to update the codex daemon. Thank you!
brennanb2025 commentedon Sep 30, 2026
Quick clarification for the original report: the
ssh, agent-browser and cookie-import windows from the first post were fixed on Orca's side in #15746 and #15887 (both shipped in 1.4.190). Those replaced #10497 and #10636. The Codex windows discussed later in the thread are the ones fixed upstream in Codex 0.159.2.If you still see windows on current Orca, with your Codex background server on 0.159.2 or later, please open a new issue with your Orca and agent versions. That especially applies to Grok, which we weren't able to verify. @LotusRenge, we couldn't reproduce the duplicate
claude-hook.cmdentry in Orca's managed Codex home. If you still have it, a new issue with your%APPDATA%\orca\codex-runtime-home\home\hooks.jsonwould help. The daemon keeping terminals (and agents in them) running after Orca closes is intentional, so they're still there when you reopen Orca.