Jss: devDependencies do not work in Node 7

Created on 30 Oct 2016  ·  20Comments  ·  Source: cssinjs/jss

I wanted to send pull request but just increasing a version is not enough. devDependencies won’t install on Node 7 because of codecov which uses deprecated version of graceful-fs and this is the latest version of codecov.

❯ npm i
npm WARN deprecated [email protected]: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.

...

❯ npm ls graceful-fs
[email protected] /Users/tema/jss
...
├─┬ [email protected]
│ └─┬ [email protected]
│   └─┬ [email protected]
│     └─┬ [email protected]
│       └── [email protected]
...

They have an issue for that since June: https://github.com/codecov/codecov-node/issues/19.

All 20 comments

Hmm, can we have different engines for dev and prod? Because its a dev only dependency.

Oh actually it shouldn't be a problem as long as we don't use engine-strict. You still can use node 7, right?

The only problem you get is when you try to install it for development, not as a dependency.

Yeah, it works fine but breaks the CI.

We can temporarily remove coverage, because it is actually currently broken anyways #301

Cool ;-)

Hmm, the probl is it is used not just in jss repository, but in many others, so maybe it is still better to actually fix this.

There’s even a quite old PR with a fix: https://github.com/codecov/codecov-node/pull/22

A workaround yarn install --ignore-engines

I’m thinking about the right solution for this problem because it also won’t install in Node 4. And yarn treat engines as a an error, while npm as just a warning.

Probably we should use engines only to specify requirements for package consumers, not for developers. For JSS I’d set it for >= 4.

For developers engine field of packages in devDependencies should be used. For example if you have eslint in devDependencies it won’t install on Node 0.12 no matter what you have in engines yourself.

What do you think?

Hmm, how would you know which node version to use if you want to install it for development? Documentaiton?

I think you are actually right, using node/npm for installing frontend packages brought this ambiguity for engines, it was always ment for the end users in node.

Contribution guidelines I think is the best place since there's no way to separate engine requirements.

Sometimes problems are so easy to fix!

Will you accept PRs with these changes? Update engines to >=4 in jss, react-jss, etc.

yes!

Done!

A fix is pushed but no new version is released, so this is still an issue.

Still an issue for me. Is there any progress on this?

This has been fixed long time ago!!! You probably experience something else, please create a new issue.

Was this page helpful?
0 / 5 - 0 ratings