fix(windows): add windowsHide to all spawn sites to prevent periodic console flash - #927
Open
grim-susemi wants to merge 5 commits into
Open
fix(windows): add windowsHide to all spawn sites to prevent periodic console flash#927grim-susemi wants to merge 5 commits into
grim-susemi wants to merge 5 commits into
Conversation
grim-susemi
force-pushed
the
fix/windows-hide-periodic-flash
branch
from
August 17, 2026 20:38
3a25102 to
ab1aaea
Compare
…console flash Every spawn without windowsHide briefly creates a visible conhost window on Windows. This adds windowsHide:true to all remaining Node child_process spawn sites that were missing it, matching the existing convention in hooks/command-runner.ts and core/tools/bash.ts: - cli.ts (main entry re-spawn) - core/exec.ts (generic execCommand) - core/tools/find.ts, grep.ts (fd / rg helpers) - modes/app-server/daemon.ts (app-server daemon) - modes/rpc/rpc-client.ts (RPC child) - utils/open-browser.ts (browser launcher) - self-update-bootstrap.ts (npm update step) - modes/interactive/external-editor.ts (external editor) - beta/omo-local-update-worker.ts (detached worker) Fixes periodic 'senpi' terminal window flash reported on Windows.
Previous commit covered 10 spawn sites but left the central wrapper
and ~22 additional sites uncovered, so periodic console flashes
could still recur on Windows.
- utils/child-process.ts: centralize enforcement — spawnProcess/
spawnProcessSync now force windowsHide:true on win32 unless caller
explicitly opts out (windowsHide:false), with cross-spawn
parsed.options propagation
- config.ts, package-manager-cli.ts, core/package-manager.ts:
spawnProcess/SpawnSync wrappers now pass windowsHide
- core/footer-data-provider.ts: git spawnSync/execFile
- utils/{clipboard-image,clipboard,paths,shell,tools-manager}.ts:
auxiliary spawns (xattr/setfattr/which/--version/wl-copy)
- core/extensions/builtin/{cursor-cli-oauth/*,mcp/diagnose.ts}:
version probes and MCP diagnostics
- modes/interactive/{interactive-mode.ts,components/session-selector.ts}:
tmux/gh/trash helpers
Total src call sites 40/40 with windowsHide in ±12-line window
(RED 22 on branch before this commit → GREEN 0). Non-Windows
behavior unchanged — win32 guard preserves original options on POSIX.
grim-susemi
force-pushed
the
fix/windows-hide-periodic-flash
branch
from
August 18, 2026 07:51
110588c to
fa1de2f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
문제
Windows에서 주기적으로 senpi 이름의 콘솔 창이 깜빡이는 현상 보고.
원인
child_process.spawn에windowsHide: true가 빠진 모든 spawn 지점에서 Windows가 conhost 창을 순간적으로 생성한다. 기존 코드에서는hooks/command-runner.ts,core/tools/bash.ts등 일부에만windowsHide가 적용되어 있고, 아래 지점들은 누락되어 있었다:packages/coding-agent/src/cli.ts— 메인 진입 재-spawnpackages/coding-agent/src/core/exec.ts— 범용 execCommandpackages/coding-agent/src/core/tools/find.ts,grep.ts— fd/rg 헬퍼packages/coding-agent/src/modes/app-server/daemon.ts— app-server 데몬packages/coding-agent/src/modes/rpc/rpc-client.ts— RPC childpackages/coding-agent/src/utils/open-browser.ts— 브라우저 런처packages/coding-agent/src/self-update-bootstrap.ts— npm 업데이트 스텝packages/coding-agent/src/modes/interactive/external-editor.ts— 외부 에디터packages/coding-agent/src/beta/omo-local-update-worker.ts— detached worker (detached:true 와 함께여도 windowsHide 필요)주기성 자체는 정상 동작일 수 있다 (예:
app-server데몬 health-check / LSP 데몬 ensure,senpi update백그라운드 worker 등) — 기능은 유지하되 창을 숨긴다.수정
누락된 모든
spawn호출에windowsHide: true추가.detached: true가 있는 곳도 Windows에서는windowsHide가 별도로 필요하다.검증
senpi --help정상grep -rn windowsHide packages/coding-agent/src로 전체 커버리지 확인영향
Windows 전용 동작만 변경, 다른 플랫폼 영향 없음.
Summary by cubic
Prevents periodic console flashes on Windows by hiding all child processes. Previously some spawns briefly opened a conhost window; now every spawn site sets windowsHide:true and the central wrappers enforce it on win32.
utils/child-process.tsforceswindowsHide:trueforspawnProcess/spawnProcessSyncon win32 unless a caller passeswindowsHide:false(propagated throughcross-spawn).windowsHide:trueto remaining directspawn/spawnSync/execFilecalls across the CLI re-spawn, core exec/package manager, git probes, app-server daemon, RPC client, browser launcher, self-update flows, external editor, interactive helpers (tmux,gh,trash), extensions (Cursor OAuth probes, MCP diagnostics), and utilities (wl-copy,xattr/setfattr,which,--versionprobes); detached spawns now also hide on Windows.VersionProbeOptionsacceptswindowsHide.windowsHide:falsewhen callingspawnProcess/spawnProcessSyncor in directspawn/execFileoptions.Written for commit 5628f5b. Summary will update on new commits.