forge icon indicating copy to clipboard operation
forge copied to clipboard

[Bug] An error when trying to install forge during import

Open Fyphen1223 opened this issue 1 year ago • 2 comments

Preflight Checklist

Electron Version

29.2.0

What operating system are you using?

Windows

Operating System Version

Windows 11

What arch are you using?

x64

Last Known Working Electron version

No response

Expected Behavior

When trying to run this command npx electron-forge import from the get started page, I got this error:

An unhandled rejection has occurred inside Forge:
Error: Failed to install modules: ["electron-squirrel-startup"]

With output: Command failed with a non-zero return code (1):
npm install electron-squirrel-startup --save

npm ERR! Cannot read properties of null (reading 'matches')

Some error text are reducted due to privacy, if you need this for debugging, I'll post it as soon as possible.

Actual Behavior

Should just install the library that are necessary to compile the files.

Testcase Gist URL

No response

Additional Information

No response

Fyphen1223 avatar Apr 06 '24 05:04 Fyphen1223

@Fyphen1223 Are you able to npm install electron-squirrel-startup --save outside of the context of the import script?

erickzhao avatar Apr 18 '24 20:04 erickzhao

@erickzhao Thanks for the reply! I actually have tried to install electron-squirrel-startup but I couldn't because of an error. If you need the error log, I'll put that later (sry, I'm currently away with my PC)

Fyphen1223 avatar Apr 19 '24 02:04 Fyphen1223