Skip to content

fix: resolve browser cookies login issue after trigger merged#1397

Merged
4pmtong merged 10 commits intomainfrom
fix/windows-npx-createprocess-cmd
Mar 3, 2026
Merged

fix: resolve browser cookies login issue after trigger merged#1397
4pmtong merged 10 commits intomainfrom
fix/windows-npx-createprocess-cmd

Conversation

@nitpicker55555
Copy link
Collaborator

@nitpicker55555 nitpicker55555 commented Mar 1, 2026

Summary

  • On Windows, subprocess.Popen uses CreateProcess which cannot execute .cmd files directly, causing FileNotFoundError when launching the Electron login browser via bare npx command in the packaged app
  • Resolve npx path via ~/.eigent/bin/npx.cmd or shutil.which fallback, wrap with cmd.exe /d /s /c on Windows, and ensure ~/.eigent/bin is on PATH for the spawned process
image

Closes #1376

Test plan

  • Verify browser login launches correctly on Windows packaged app
  • Verify no regression on macOS/Linux

🤖 Generated with Claude Code

On Windows, subprocess.Popen uses CreateProcess which cannot execute
.cmd files directly. This causes FileNotFoundError when launching the
Electron login browser via bare "npx" command in the packaged app.

Fix by:
- Resolving npx path via ~/.eigent/bin/npx.cmd or shutil.which fallback
- Wrapping the command with cmd.exe /d /s /c on Windows
- Ensuring ~/.eigent/bin is on PATH for the spawned process

Closes #1376
@nitpicker55555
Copy link
Collaborator Author

@bytecii Fixed

@nitpicker55555 nitpicker55555 changed the title fix: resolve npx path on Windows for browser login launch fix: resolve browser cookies login issue after trigger merged Mar 3, 2026
Copy link
Collaborator

@4pmtong 4pmtong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Thanks @nitpicker55555

@4pmtong 4pmtong merged commit ce86175 into main Mar 3, 2026
8 checks passed
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.

[BUG] /browser/login reports “launched” even if Electron exits quickly [BUG] Browser does not launch on Windows

4 participants