Electron-forge: TypeError [ERR_INVALID_ARG_TYPE]: The "file" argument must be of type string. Received an instance of Object

Created on 29 Jan 2021  路  2Comments  路  Source: electron-userland/electron-forge

Issue Details

Electron Forge Version: 6.0.0-beta.54
Electron Version: ^12.0.0-beta.18
Operating System: Windows 10

Expected Behavior
npm start - start the Electron application

Actual Behavior

Error - An unhandled error has occurred inside Forge:
The "file" argument must be of type string. Received an instance of Object
TypeError [ERR_INVALID_ARG_TYPE]: The "file" argument must be of type string. Received an instance of Object
at validateString (internal/validators.js:124:11)
at normalizeSpawnArguments (child_process.js:411:3)
at spawn (child_process.js:551:13)

Bug

Most helpful comment

For me, this happened when I had electron-prebuilt-compile in my devDependencies, which I did not need. Removing it solved the issue.

All 2 comments

I can't reproduce this with Windows 10, Powershell, and the information provided. Steps:

npx create-electron-app forge-2141
cd forge-2141
npm install --save-dev electron@^12.0.0-beta.8
npm start

The Electron app starts for me.


Please add any details to your reproduction steps necessary for this to behave as described, and I'll reopen if I can reproduce it here and it is indeed a bug in Electron Forge.

For me, this happened when I had electron-prebuilt-compile in my devDependencies, which I did not need. Removing it solved the issue.

Was this page helpful?
0 / 5 - 0 ratings