mirror of
https://github.com/MoonshotAI/kimi-code.git
synced 2026-07-09 17:29:12 +00:00
Two distinct PTY failures: - 'Failed to load native module: pty.node' (npx/published daemon): node-pty was transitively bundled via @moonshot-ai/services (alwaysBundle), inlining its JS while its native binary can't be bundled and wasn't shipped. Mark node-pty external in tsdown (neverBundle) and declare it as a runtime dependency of @moonshot-ai/kimi-code so npm/npx installs it with its prebuilt pty.node. - 'posix_spawnp failed' (local pnpm dev): node-pty's prebuilds/*/spawn-helper loses its +x bit through pnpm's store extraction. Add a root postinstall (scripts/fix-node-pty-perms.mjs) that restores the executable bit; verified it fixes a reproducible spawn failure. Also harden defaultShell() to fall back on an empty (not just unset) $SHELL. Note: the SEA standalone binary still needs node-pty's pty.node + spawn-helper wired into scripts/native/native-deps.mjs (not addressed here; npx path covers the reported case). |
||
|---|---|---|
| .. | ||
| check-nix-workspace.mjs | ||
| check-service-naming.mjs | ||
| fix-node-pty-perms.mjs | ||