Skip to content
This repository was archived by the owner on Apr 24, 2026. It is now read-only.

Commit bcf80e9

Browse files
lanmowerclaude
andcommitted
fix: spawn node not bun for bash node commands on Windows
Bun's event loop exits after top-level await resolves, killing long-running servers. Use actual node binary which keeps the event loop alive for http.listen(). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 2c2a1a9 commit bcf80e9

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/runtime.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ export function spawnProcess(runtime, code, cwd) {
7070
const parts = code.match(/^\s*cd\s+(\S+)\s*&&\s*node\s+(.+)$/);
7171
const nodeCwd = parts ? parts[1].replace(/['"]/g, '') : cwd;
7272
const nodeArgs = (parts ? parts[2] : nodeMatch[1]).trim().split(/\s+/);
73-
const child = spawn('bun', nodeArgs, spawnOpts(nodeCwd || cwd));
73+
const child = spawn('node', nodeArgs, spawnOpts(nodeCwd || cwd));
7474
return { child, cleanup };
7575
}
7676
if (IS_WIN) {

0 commit comments

Comments
 (0)