Skip to content

fix: resolve Windows desktop build spawn EINVAL error#147

Merged
bbsngg merged 2 commits intomainfrom
fix/windows-desktop-spawn-einval
Apr 8, 2026
Merged

fix: resolve Windows desktop build spawn EINVAL error#147
bbsngg merged 2 commits intomainfrom
fix/windows-desktop-spawn-einval

Conversation

@bbsngg
Copy link
Copy Markdown
Contributor

@bbsngg bbsngg commented Apr 8, 2026

Summary

  • Fix spawn EINVAL error when building Windows desktop app in CI
  • On Windows, .cmd files (npm.cmd/npx.cmd) require shell: true to be spawned by Node.js child_process.spawn()
  • Changed shell: false to shell: process.platform === 'win32' in electron/cli.mjs so Windows CI builds work while macOS/Linux remain unaffected

Test plan

  • Verify Windows desktop build (desktop-release.yml) completes successfully in CI
  • Verify macOS desktop build still works

🤖 Generated with Claude Code

bbsngg and others added 2 commits April 8, 2026 09:59
Spawning .cmd files (npm.cmd/npx.cmd) on Windows requires shell: true.
Set shell conditionally based on platform to fix CI desktop builds.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Also fix npx binary name for Windows (.cmd extension required) and
enable shell mode on Windows for both cli.mjs and native-runtime.mjs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@bbsngg bbsngg merged commit 29281ba into main Apr 8, 2026
4 checks passed
@bbsngg bbsngg deleted the fix/windows-desktop-spawn-einval branch April 8, 2026 17:33
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