Skip to content

fix: spawn codegraph CLI on Windows without a shell (EINVAL on .cmd s… - #2

Open
icyrains wants to merge 3 commits into
jiangzhenguo:mainfrom
icyrains:main
Open

icyrains wants to merge 3 commits into
jiangzhenguo:mainfrom
icyrains:main

Conversation

@icyrains

Copy link
Copy Markdown

…him)

resolveExecutable('codegraph') returns a .cmd shim on Windows; spawning it without a shell throws EINVAL on Node >= 18.20. Expand the shim's real argv prefix and spawn that directly, falling back to cmd.exe /d /s /c. Also pass CODEGRAPH_NO_WATCHDOG=1 so short-lived CLI spawns aren't mis-killed by the #850 liveness watchdog during cold-start index/sync.

…him)

resolveExecutable('codegraph') returns a .cmd shim on Windows; spawning it without a shell throws EINVAL on Node >= 18.20. Expand the shim's real argv prefix and spawn that directly, falling back to cmd.exe /d /s /c. Also pass CODEGRAPH_NO_WATCHDOG=1 so short-lived CLI spawns aren't mis-killed by the #850 liveness watchdog during cold-start index/sync.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant