Closed Daniel15 closed 7 years ago
Having the same issue... makes the output look like there was an issue when running 'yarn install' and eats some extra seconds.
this problem should be solved with https://github.com/yarnpkg/yarn/pull/1997
Yes, confirmed fixed in latest nightly build:
yarn install v0.18.0-20161129.2058
info No lockfile found.
warning sitename@0.0.0: No license field
[1/4] Resolving packages...
warning babel-core > minimatch@2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
[2/4] Fetching packages...
warning fsevents@1.0.15: The platform "win32" is incompatible with this module.
info "fsevents@1.0.15" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Saved lockfile.
Doesn't seem to be fixed for linux. npm run yarn
just runs yarn
. The build is stuck forever after this warning.
Successfully built 926b219559f2
+ docker run --rm -v /var/jenkins_home/workspace/cloud-ui@2/cloud-ui:/src adminconsole-node:latest /bin/sh -c '
set -ex;
npm prune;
npm install yarn >/dev/null;
npm run yarn > /dev/null;
npm run verify-deps;
npm run lint;
CI=true npm test;
'
+ npm prune
+ npm install yarn
npm WARN prefer global yarn@0.18.0 should be installed with -g
+ npm run yarn
warning fsevents@1.0.15: The platform "linux" is incompatible with this module.
I am getting this error on a windows 7 machine and IT IS blocking me since I can't get any packages to install when it hits.
Still seeing this issue with yarn 1.9.4 on Azure DevOps (formerly VSTS)
Same issue on 1.9.4 with:
"resolutions": {
"**/fsevents": ">=1.2.4"
}
It seems that this issue is back.
~Possibly related: I am on macOS, and fsevents is rebuilding every time I run yarn
, even if the correct version is already installed.~
~I don't think that used to happen. I think yarn
used to finish immediately with the message "success Already up-to-date."~
~Of the 11 dependencies that need to be built on a fresh install, fsevents
is the only dependency which rebuilds on every install.~
Update: I am happy to report that, after upgrading from 1.10.1 to 1.12.1, this problem has stopped. We have got the "Already up-to-date" message back, and short install times. Thank you!
Getting this issue with 1.10.1 too on linux
People getting this problem, you might try upgrading from 1.10.1 to 1.12.1. That has fixed it for us.
Getting this issue with 1.12.3, the install aborts with an error:
error fsevents@1.2.4: The platform "linux" is incompatible with this module.
error Found incompatible module
Used to be a warning and the module used to be ignored.
This is with running yarn --pure-lockfile --production
or yarn
Are you sure fsevents is listed as an optional dependency? If it's not optional, it'll fail on Linux, which is expected.
Sent from my phone.
On Sun, Dec 30, 2018, 3:12 PM Adam Reis <notifications@github.com wrote:
Getting this issue with 1.12.3, the install aborts with an error:
error fsevents@1.2.4: The platform "linux" is incompatible with this module. error Found incompatible module
Used to be a warning and the module used to be ignored.
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/yarnpkg/yarn/issues/2051#issuecomment-450593265, or mute the thread https://github.com/notifications/unsubscribe-auth/AAFnHb-blfOUg-LYdjrhDhh2wdpL6DTQks5u-UhygaJpZM4K9Tb7 .
It is a nested optional dependency, but I discovered that the problem was due to the following added lines in package.json
:
"resolutions": {
"nodemon/chokidar/fsevents": "1.2.4"
}
This was needed to make it work with Node 10, but apparently manually adding the resolution forces yarn to try and install the package, even if it's an optional dependency.
Also saw this error. Updating node from 6 to 8 fixed it for us.
https://travis-ci.org/ember-infinity/ember-infinity/jobs/478166551
I also encountered this again, we had fsevents in resolutions because of some prior issue, but that wasn't necessary anymore. However, I still think yarn shouldn't fail on an optional package, even if it's specified in the resolutions. Those resolutions should only be used if the package is actually installed (which it shouldn't on linux).
Yarn still got this
PROMPT>yarn global add @nestjs/cli yarn global v1.13.0
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.2.7: The platform "win32" is incompatible with this module. info "fsevents@1.2.7" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
I had to use npm force install for this.
But did it worked afterwards? In my case not.
Still seeing it in 1.15.2, this is in a fresh node:8 container
yarn --network-timeout 100000 install
yarn install v1.15.2
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
info fsevents@1.2.9: The platform "linux" is incompatible with this module.
info "fsevents@1.2.9" is an optional dependency and failed compatibility check. Excluding it from installation.
[4/5] Linking dependencies...
Windows 10 Build 16299 system output:
λ yarn install
yarn install v1.17.3
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.2.9: The platform "win32" is incompatible with this module.
info "fsevents@1.2.9" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
Done in 61.98s.
My package.json:
{
"name": "Test",
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"lint": "vue-cli-service lint"
},
"dependencies": {
"core-js": "^2.6.5",
"vue": "^2.6.10",
"vue-router": "^3.0.6"
},
"devDependencies": {
"@vue/cli-plugin-babel": "^3.7.0",
"@vue/cli-plugin-eslint": "^3.7.0",
"@vue/cli-service": "^3.7.0",
"@vue/eslint-config-standard": "^4.0.0",
"babel-eslint": "^10.0.1",
"eslint": "^5.16.0",
"eslint-plugin-vue": "^5.0.0",
"tailwindcss": "1.1",
"vue-template-compiler": "^2.6.10"
}
}
Try this
yarn config set ignore-engines true
Try this
yarn config set ignore-engines true
Thanks, this worked in my case too.
@ryantando
Try this
yarn config set ignore-engines true
Should that^^ stop the incessant, every-time-yarn-execs noise,
...
[2/4] Fetching packages...
info fsevents@1.2.9: The platform "linux" is incompatible with this module.
info "fsevents@1.2.9" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@2.1.1: The platform "linux" is incompatible with this module.
info "fsevents@2.1.1" is an optional dependency and failed compatibility check. Excluding it from installation.
...
as well?
If not, any hints as to what can/does?
I am still facing this issue with v1.22.4
yarn add notistack yarn add v1.22.4 [1/4] Resolving packages... [2/4] Fetching packages... info fsevents@2.1.2: The platform "win32" is incompatible with this module. info "fsevents@2.1.2" is an optional dependency and failed compatibility check. Excluding it from installation. info fsevents@1.2.12: The platform "win32" is incompatible with this module. info "fsevents@1.2.12" is an optional dependency and failed compatibility check. Excluding it from installation. [3/4] Linking dependencies... warning " > react-ga@2.7.0" has unmet peer dependency "prop-types@^15.6.0". warning "react-scripts > @typescript-eslint/eslint-plugin > tsutils@3.17.1" has unmet peer dependency "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta".
I believe it somehow effects my surge deployment process. I'm creating a workflow in github actions but it fails.
yarn remove v1.22.4 [1/2] Removing module cra-template... [2/2] Regenerating lockfile and installing missing dependencies... info fsevents@2.1.2: The platform "win32" is incompatible with this module. info "fsevents@2.1.2" is an optional dependency and failed compatibility check. Excluding it from installation. info fsevents@1.2.12: The platform "win32" is incompatible with this module. info "fsevents@1.2.12" is an optional dependency and failed compatibility check. Excluding it from installation. warning " > @testing-library/user-event@7.2.1" has unmet peer dependency "@testing-library/dom@>=5". warning "react-scripts > @typescript-eslint/eslint-plugin > tsutils@3.17.1" has unmet peer dependency "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta". success Uninstalled packages.
@adisher It's just a warning and shouldn't actually break anything.
Try this
yarn config set ignore-engines true
What are the side effects of this call?
@papadi Well, this is the yarn documentation for yarn install --ignore-engines
:
Do not execute any scripts defined in the project package.json and its dependencies.
So I assume that somewhere in the install chain there is some script that tries to install fsevents. But turning this off for ever seems a bit more than required. You could just try running yarn install --ignore-engines
for this case.
I need to switch to a specific node version and it worked. :)
I need to switch to a specific node version and it worked. :)
And what version of node
was that?
Try this
yarn config set ignore-engines true
It's work !!!
I have executed the yarn
command in the GitHub Desktop app's repository and got the following "info" severity messages:
info fsevents@2.2.1: The platform "win32" is incompatible with this module. info "fsevents@2.2.1" is an optional dependency and failed compatibility check. Excluding it from installation.
I'm not sure what exactly is the "optional dependency" and what consequences the fact that it's not being installed may have. Should I just ignore it? I have tried to use the option --ignore-engines
with both yarn
and yarn install
but those messages are still being produced. I'm not sure I want to set it globally in the config as I don't know what consequences it may have (e.g. what potential errors I may miss).
@ferenczy ,
FS Events is kinda pain in ***, if you are facing issues in your project creation or build at any point of time, consider using npm install --no-optional
flag while installing your package(s) which are producing this error. If you're not facing any issues but freaked out (like me, few months back), you have 2 options,
Option A) - Simply ignore as it is optional dependency(most of the time)
OR
Option B) - Switch to other supported OS, if you are comfortable working in non-windows OS enviornment.
For some reason, yarn config set ignore-engines true
and yarn install --ignore-engines
aren't bypassing the resolutions / optional dependency issue, at least in our Github CI build with actions/setup-node@v2
.
It is a nested optional dependency, but I discovered that the problem was due to the following added lines in
package.json
:"resolutions": { "nodemon/chokidar/fsevents": "1.2.4" }
This was needed to make it work with Node 10, but apparently manually adding the resolution forces yarn to try and install the package, even if it's an optional dependency.
This is fixed in yarn v2 https://github.com/yarnpkg/yarn/issues/7590 🎉
For those of who are still using yarn v1..... instead of pinning fsevents
directly in resolutions, you can pin a newer version of whatever dependency is pulling in fsevents. In our case, chokidar was listing fsevents as an optional dependency. So I found the newer version of chokidar that began consuming the fsevents version I need, then I set this version in package.json:
"resolutions": {
...
"chokidar": "^3.5.0"
},
After 1000+ days, the saga still continues.. Sometimes developers get so much caught in the dependency drains. @locofocos . Thanks for posting this.
BTW, as far as I recall, When I switched to PNPM, I never got this issue.
@locofocos Can you please check that option as well ! If you have provision for checking the alternative package manager. That would be a great help. Thanks.
Do you want to request a feature or report a bug? Bug
What is the current behavior?
fsevents
is only relevant on Mac OS, it does not compile on Linux or Windows. Yarn appears to try and compile it even on incompatible operating system. This is a waste of time as it's always going to fail.If the current behavior is a bug, please provide the steps to reproduce. This is the
package.json
from one of my sites:Running
yarn
gives me this as part of the output:However, in the "Building fresh packages..." stage of installation, it still attempts to build the dependency, which obviously fails as it should only be built on Mac OS.
The installation still succeeds so this is not a blocker, it's just very odd behaviour.
The second time I run
yarn
, it shows that everything is up-to-date:However, when I add another dependency, it tries to build fsevents again.
What is the expected behavior? Yarn should not attempt to build a native dependency if it's incompatible with the current OS
npm handles this correctly:
Please mention your node.js, yarn and operating system version. Yarn 0.17.8 Windows 10 Node.js 6.9.1