Creating/Starting new project fails with error "Error: Electron version 1.4.15 is either too old or too new"
See original GitHub issue- I have read the contribution documentation for this project.
- I agree to follow the code of conduct that this project follows, as appropriate.
- I have searched the issue tracker for an issue that matches the one I want to file, without success.
Please describe your issue: Created a new application, started the application and received the following error:
App threw an error during load
Error: Electron version 1.4.15 is either too old or too new (While processing preset: "/Users/leifwells/Code/electron/ef-test/node_modules/babel-preset-env/lib/index.js")
at getTargets (/Users/leifwells/Code/electron/ef-test/node_modules/babel-preset-env/lib/index.js:144:13)
at buildPreset (/Users/leifwells/Code/electron/ef-test/node_modules/babel-preset-env/lib/index.js:209:17)
at /Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/options/option-manager.js:317:46
at Array.map (native)
at OptionManager.resolvePresets (/Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/options/option-manager.js:275:20)
at OptionManager.mergePresets (/Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/options/option-manager.js:264:10)
at OptionManager.mergeOptions (/Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/options/option-manager.js:249:14)
at OptionManager.init (/Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
at File.initOptions (/Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/index.js:216:65)
at new File (/Users/leifwells/Code/electron/ef-test/node_modules/babel-core/lib/transformation/file/index.js:139:24)
Console output when you run electron-forge
with the environment variable DEBUG=electron-forge:*
. (Instructions on how to do so here). Please include the stack trace if one exists.
Put the console output here
What command line arguments are you passing?
electron-forge init ef-test
cd ef-test
electron-forge start
What does your config.forge
data in package.json
look like?
"config": {
"forge": {
"make_targets": {
"win32": [
"squirrel"
],
"darwin": [
"zip"
],
"linux": [
"deb",
"rpm"
]
},
"electronPackagerConfig": {},
"electronWinstallerConfig": {
"name": "ef_test"
},
"electronInstallerDebian": {},
"electronInstallerRedhat": {},
"github_repository": {
"owner": ""
},
"windowsStoreConfig": {
"packageName": "",
"name": "eftest"
}
}
},
Please provide either a failing minimal testcase (with a link to the code) or detailed steps to
reproduce your problem. Using electron-forge init
is a good starting point, if that is not the
source of your problem.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:2
- Comments:14 (7 by maintainers)
Top Results From Across the Web
Error: Electron failed to install correctly, please delete ... - GitHub
Failed at the electron@1.4.15 postinstall script 'node install.js'. npm ERR! Make sure you have the latest version of node.js and npm installed.
Read more >Error when building my electron app - Stack Overflow
It works perfectly when running npm start . But, when I execute the command build -w (for windows) it fails with this log....
Read more >electron-prebuilt - npm
Electron is a JavaScript runtime that bundles Node.js and Chromium. You use it similar to the node command on the command line for...
Read more >Advanced Installation Instructions | Electron
To install prebuilt Electron binaries, use npm. The preferred method is to install Electron as a development dependency in your app:
Read more >electron-packager
About. Electron Packager is a command line tool and Node.js library that bundles Electron-based application source code with a renamed Electron executable and ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@malept yeah I can confirm it’s working fine now. Thanks
The workaround is: pin
babel-preset-env
to 1.1.8.