Closed ghost closed 4 years ago
Thank you for opening this!
We're aware of these warnings but are currently bound to certain versions due to some dependencies. You won't need to do anything and you can ignore those warnings. Eventually we'll resolve those.
We're marking this issue as answered and closing it for now but please feel free to comment here if you would like to continue this discussion. We also recommend heading over to our communities if you have questions that are not bug reports or feature requests. We hope we managed to help and thank you for using Gatsby!
We're aware of these warnings but are currently bound to certain versions due to some dependencies. You won't need to do anything and you can ignore those warnings. Eventually we'll resolve those.
@LekoArts what is the status on Chokidar warnings about breakage on node 14?
For watchpack, the maintainer was against updating to v3 of Chokidar due to supporting node v6 still(despite EOL status). Their current watchpack v2 beta is dropping chokidar entirely for some reason, with webpack v5 to use that instead, against the concerns raised by chokidar maintainer.
The current watchpack v1.x release did get chokidar v3 support, as some users were experiencing issues with chokidar v2 in node 14+. However watchpack supports this by making chokidar v2 and v3 optional dependencies. I'm not sure but I assume that's downloading both packages, so the warning about v2 with watchpack could be superfluous?
There is a few other warnings for other packages that reference chokidar v2 however, is there a tracking issue/PR for where these will eventually be resolved? I've been tracking down the dependencies and can see that some appear unmaintained for 1-2 years or so, or failed to push a new release out.
The main gatsby
package has an outdated semver:
That package reached a 1.0.2
release back in April 2019. Version 0.3.3
(Aug 2018) is what gets installed still today however, and the project repo itself lacks any commits since Sep 2018.
It continues to list chokidar v2 as an optional dependency, but I'm not sure if that allows for overriding it elsewhere with chokidar v3(which is API compatible apart from an async close()
and requiring node 8+).
If a dependency can be used, but you would like npm to proceed if it cannot be found or fails to install, then you may put it in the
optionalDependencies
object. This is a map of package name to version or url, just like thedependencies
object. The difference is that build failures do not cause installation to fail. Entries inoptionalDependencies
will override entries of the same name independencies
, so it’s usually best to only put in one place. - NPM docs - optionalDependency
Update eslint-plugin-graphql
to 4.0.0 to remove deprecation warning(I was originally going to submit an issue for this).
Doesn't appear to be any issue/PR for it, renovate-bot hasn't picked up on it.
Updating to 4.0.0
will remove a warning during install:
warning gatsby > eslint-plugin-graphql > graphql-config > graphql-import@0.7.1: GraphQL Import has been deprecated and merged into GraphQL Tools, so it will no longer get updates. Use GraphQL Tools instead to stay up-to-date! Check out https://www.graphql-tools.com/docs/migration-from-import for migration and https://the-guild.dev/blog/graphql-tools-v6 for new changes.
The micromatch
/ snapdragon
issue, I raised an issue with. The snapdragon
package hasn't seen any activity since 2018, but micromatch
which is maintained by the same devs has been active. There's already been a PR sitting around with the fix in snapdragon
, but it hasn't been responded to. I raised an issue on micromatch
repo to raise awareness of that.
I've also raised an issue for the request
package deprecation in probe-image-size
.
Hopefully those projects will update their dependencies and publish a new release.
One of the core-js warnings for upgrading to v3 relies on the fbjs
package which has not seen a release since 2018, several months ago a maintainer did merge a PR updating the dependency, but there was no associated package version bump and release, so that's stuck while relied upon.
Benefits by the chokidar maintainer for v3 are mentioned here:
We've released Chokidar 3 in April. See my post on that: Chokidar 3: How to save 32TB of traffic every week with one NPM package
The changes are pretty big. First of all, the package is 16 times smaller and uses 15 dependencies instead of 201. We've switched to n-api, which means users won't download fsevents binaries anymore. n-api is included in every nodejs installation, and it's tiny. Directory walking has been improved massively with stream implementation of readdirp. Massive RAM & CPU improvements etc.
From the blogpost link:
Switching node-fsevents to N-API, a new API for building native addons. In v2, we’ve been using node-gyp, which is buggy, sloppy, and produced useless errors while compiling. Rewriting readdirp — another module of ours — to a stream API. Allowed to reduce memory consumption by a factor of 5 in some cases To handle globs, we’ve rewritten picomatch and braces to use its own parsers instead of 3-rd party dep. This allowed to drop dependency count significantly.
~8MB package size down to ~500KB. node-gyp
has caused plenty of problems for me, though I think that's still used elsewhere for some packages in sharp depending on system installed on.
Hello +1 to that. I'm feeling increasingly uneasy about these warnings too. @shreyansh-zazz can you reopen the issue ?
Hi @alvincodes
I don't have permission to reopen this issue.
Following are the warnings that appear while doing
npm i
oryarn install
:warning gatsby > babel-plugin-add-module-exports > chokidar@2.1.8: Upgrade to chokidar 3 with 15x less dependencies. Chokidar 2 will break on node v14.
warning gatsby > core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
warning gatsby > @babel/polyfill > core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
warning gatsby > gatsby-cli > core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
warning gatsby > webpack-dev-server > chokidar@2.1.8: Upgrade to chokidar 3 with 15x less dependencies. Chokidar 2 will break on node v14.
warning gatsby > @pmmmwh/react-refresh-webpack-plugin > react-dev-utils > fork-ts-checker-webpack-plugin > chokidar@2.1.8: Upgrade to chokidar 3 with 15x less dependencies. Chokidar 2 will break on node v14.
warning gatsby > webpack > watchpack > chokidar@2.1.8: Upgrade to chokidar 3 with 15x less dependencies. Chokidar 2 will break on node v14.
warning gatsby > gatsby-cli > yurnalist > babel-runtime > core-js@2.6.11: core-js@<3 is no longer maintained and not recommended for usage due to the number of issues. Please, upgrade your dependencies to the actual version of core-js@3.
warning gatsby > micromatch > snapdragon > source-map-resolve > resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
warning gatsby > micromatch > snapdragon > source-map-resolve > urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
warning gatsby-plugin-sharp > probe-image-size > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning gatsby-transformer-remark > remark > unified > @types/vfile > @types/vfile-message@2.0.0: This is a stub types definition. vfile-message provides its own type definitions, so you do not need this installed.
warning node-sass > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning node-sass > node-gyp > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning "gatsby > react-hot-loader@4.12.20" has unmet peer dependency "@types/react@^15.0.0 || ^16.0.0".
warning "gatsby > @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".
warning "gatsby-plugin-sass > sass-loader@7.3.1" has unmet peer dependency "webpack@^3.0.0 || ^4.0.0".