Monday 29 May 2017

Exit status 255 in electron

Several times when building electron apps I get errors exactly like this one

PS C:\users\roryo\desktop\labs\eqs> npm start

> eqs@1.0.0 start C:\users\roryo\desktop\labs\eqs
> electron .

uilt\cli.js" . was unexpected at this time.

C:\users\roryo\desktop\labs\eqs>)uilt\cli.js" .

npm ERR! Windows_NT 10.0.15063
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
npm ERR! node v7.9.0
npm ERR! npm  v4.2.0
npm ERR! code ELIFECYCLE
npm ERR! errno 255
npm ERR! eqs@1.0.0 start: `electron .`
npm ERR! Exit status 255
npm ERR!
npm ERR! Failed at the eqs@1.0.0 start script 'electron .'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the eqs package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     electron .
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs eqs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls eqs
npm ERR! There is likely additional logging output above.    
npm ERR! Please include the following file with any support request:
npm ERR!     C:\Users\roryo\AppData\Roaming\npm-cache\_logs\2017-05-29T22_37_33_920Z-debug.log

I've traced this to an issue in electron.cmd

@IF EXIST "%~dp0\node.exe" (
  "%~dp0\node.exe"  "%~dp0\..\electron\cli.js" %*
) ELSE (
  @SETLOCAL
  @SET PATHEXT=%PATHEXT:;.JS;=;%
  node  "%~dp0\..\electron\cli.js" %*
)uilt\cli.js" %*
)

If I remove the second last line )uilt\cli.js" %* I no longer get the error. Since I have an easy workaround, it's really an academic question.

Where does this issue come from? I've googled it repeatedly without success.



via roryok

No comments:

Post a Comment