Repository navigation
Description
Summary
On Windows, every shell tool call spawns a visible powershell.EXE + conhost.exe window that opens and closes rapidly. Parallel tool calls produce a cascade of flashing cmd windows.
Environment
- opencode version: 2.0.26 (skill snapshot at registration;
opencode --versionUnavailable:opencode.ps1blocked by ExecutionPolicyPSSecurityException/UnauthorizedAccess) - OS: Windows_NT 10.0.26100 (win32 x64) (skill snapshot;
verUnavailable: cmd builtin, not valid in PowerShell) - Terminal: Unavailable: no TERM/TERM_PROGRAM/COLORTERM vars (OpenCode Desktop app)
- Shell: C:\WINDOWS\system32\cmd.exe (
$ComSpec, skill snapshot) - Install/channel: latest; server =
...\ai.opencode.desktop\cli\2.0.26\opencode-cli.exe serve --service(child ofOpenCode.exe, seen inWin32_Process) - Active plugins:
opencode-supermemory@latest; localplugin/slow-connect-fix.jsfails to load (PluginModule.LoadError, see server log WARN)
Reproduction
- Windows 10/11 + OpenCode Desktop (service mode:
opencode-cli.exe serve --service). - Send any prompt that makes the agent use
shelltools, especially several in parallel (e.g. filesystem scans). - Watch the screen: one cmd/powershell window flashes open+closed per
shellcall.
Minimal probe (also the monitor's observer effect): a single shell call = 1 flash.
Expected Behavior
Tool subprocesses spawn hidden (CREATE_NO_WINDOW / windowsHide, i.e. the equivalent of -WindowStyle Hidden — like the already-hidden ollama-idle-daemon.ps1 process on the same machine, which never flashes).
Actual Behavior
Each shell call = 1× C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.EXE -NoLogo -NoProfile -NonInteractive -Command "..." (direct child of opencode-cli.exe, PID 10900 observed) + 1× conhost.exe child of it. Server log confirms: message="spawning process" command="C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\powershell.EXE" args="[-NoLogo,-NoProfile,-NonInteractive,-Command,...]" per call, with no hidden-window flag.
Measured with a 250 ms Win32_Process polling daemon (children of opencode-cli.exe + their conhost): 171 flashes intercepted in ~43 min (79× powershell.exe + 90× conhost.exe), log in cmd-watch/events.csv, server PID 10900 constant.
Additional Context
- Config docs (
https://opencode.ai/v2/docs/config) expose only"shell": "<path>"(path string, no hide-window option) — setting an explicit shell path does not provide a hide flag. [Verified 2026-10-11] - Frequency: consistent, 100% reproducible on every
shellcall. - Recent change (probable trigger, not root cause): sessions started issuing many parallel
shellcalls (10+ parallel disk scans in server log 2026-10-11 07:57–07:59 UTC); older sessions used mostlyread/grep/glob(no subprocess, no flash). - Workaround in use: batch all commands into a single
shellcall per turn with;, preferread/glob/grep/edittools (no spawn). Reduces cascade from N flashes to 1, does not eliminate it.
Activity
opencode-agent commentedon Oct 13, 2026
Thanks for the detailed measurements!
Before we go further, there's one thing we need to check. On Windows, the core
shelltool already starts its PowerShell process withwindowsHide(CREATE_NO_WINDOW), so that PowerShell shouldn't get a visible window. A hidden PowerShell still creates aconhost.exe, though. That means pollingWin32_Processshows a powershell + conhost pair for every call, whether or not a window actually appears on screen. So the 171 events confirm the processes were started, but not that those processes opened visible windows.In similar reports, the visible window came from a plugin. One was
opencode-supermemory, which you have installed: in #52281 it was found to rungitthroughexecSyncwithoutwindowsHide. Another was a plugin hook that runs before every tool call, which makes it look like every tool call flashes.Could you please:
opencode-supermemoryand the localplugin/slow-connect-fix.js(from thepluginsarray in your config and from theplugin(s)/folders), restart the Desktop app, and run a fewshellcalls. Do the flashes still happen?powershell.exe,git.exe,cmd.exe) or a screenshot or screen recording. A tool that lists visible windows (ConsoleWindowClass/CASCADIA_HOSTING_WINDOW_CLASS) instead of processes would also work. Tell us too whether your default terminal application is Windows Console Host or Windows Terminal.You can reply here with the details, or edit the issue. If you edit it, please also leave a comment saying you've updated it, so we know you're done.
These issues might already cover your problem (ordered from most to least likely):
cmd.exe(git probes, MCP spawns) flashes a visible console window and steals focus despitewindowsHidebeing set #52281: visible console windows from the Desktopserve --serviceprocess; a comment there traces them toopencode-supermemoryspawning git withoutwindowsHideopencode-agent commentedon Oct 16, 2026
We haven't heard back, so I'm closing this for now.
We were waiting to find out two things: whether the flashes still happen with
opencode-supermemoryand the localslow-connect-fix.jsplugin removed, and what the visible window actually is (its title, a screenshot, or a log of visible windows rather than processes). The coreshelltool already starts PowerShell withwindowsHide. A hidden PowerShell still creates aconhost.exe, so the process counts alone can't show where the visible windows come from.If you can check this, please reply with what you find and we can reopen the issue. Until then, these issues cover the most likely causes:
cmd.exe(git probes, MCP spawns) flashes a visible console window and steals focus despitewindowsHidebeing set #52281: a plugin (opencode-supermemory) spawns git withoutwindowsHideThanks again for the detailed report.