[yarn][beta] "engine node is incompatible" error
See original GitHub issueWhen I install the beta version (3.0.0-beta.9) of node-fetch with Yarn, Yarn returns an error:
error fetch-blob@1.0.7: The engine "node" is incompatible with this module. Expected version "^10.17.0". Got "14.15.4"
error Found incompatible module.
So I have to force the installation with --ignore-engines
.
Reproduction
Steps to reproduce the behavior:
- Install Node.js version 14 (I use v14.15.4)
- Install Yarn (
sudo npm i -g yarn
) - Create an empty folder, open it in a terminal
- Install node-fetch version 3 beta with Yarn (
yarn add --dev node-fetch@^3.0.0-beta.9
)
Expected behavior
No error because v14 is the current stable version of Node.js.
Your Environment
software | version |
---|---|
node-fetch | 3.0.0-beta.9 |
node | 14.15.4 |
yarn | 1.22.5 |
Operating System | macOS 11.4 |
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
The engine "node" is incompatible with this module
You can try to ignore the engines : $ yarn install --ignore-engines. OR. $ yarn global add <your app> --ignore-engines.
Read more >Build failed: The engine "node" is incompatible with this ...
My project is Ruby/Rails based and we use a config.yml file to setup CircleCI. There is no mention of node in it, but...
Read more >Dependency Scanning Fails: "engine 'node' is incompatible ...
Summary. Our Node.js project was successfully using Dependency Scanning for a while. It began to fail once we added a yarn.lock file.
Read more >the engine node is incompatible with this module - You.com
I updated npm as well as yarn globally on my machine, still no success. I tried without npx and it solved the problem:...
Read more >React Native Builds fail with, "The engine "node" is ...
Expected version ">=x.x.x" ; error Found incompatible module. React Native builds fail on our agents due to Node compatibility issues. Jihye E avatar....
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
Just updated - can confirm.
The reason for the issue is because of the caret. It usually declares that the most recent minor version be used but because the development versions don’t use semver, npm doesn’t understand which version to fetch. Instead, use
yarn add node-fetch@next
oryarn add node-fetch@3.0.0-beta.9
unfortunately
"node-fetch": "^3.0.0-beta.10"
would still fetch the wrong version. Sticking to fixed version for now.