newtab package.json requires old node and npm versions (10.23.*, 6.14.10) and has package version conflicts
Categories
(Firefox :: Messaging System, defect, P2)
Tracking
()
People
(Reporter: sfoster, Assigned: nsauermann)
References
(Blocks 1 open bug)
Details
Attachments
(1 obsolete file)
We have an engines configuration in package.json which requires an old version of node. If you use mach npm
and mach node
as instructed by the docs there are module version problems. The npm install step produces this error:
pm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: 'activity-streams@1.14.3',
npm WARN EBADENGINE required: {
npm WARN EBADENGINE firefox: '>=45.0 <=*',
npm WARN EBADENGINE '//': 'when changing node versions, also edit .nvmrc',
npm WARN EBADENGINE node: '10.23.*',
npm WARN EBADENGINE npm: '6.14.10'
npm WARN EBADENGINE },
npm WARN EBADENGINE current: { node: 'v16.0.0', npm: '7.10.0' }
npm WARN EBADENGINE }
And the npm run bundle
step fails. I think we need to update that package.json with the same versions that mach
is using (and ideally find a way to tie the 2 together).
Reporter | ||
Comment 1•2 years ago
|
||
I was able to get this to work temporarily by using nvm to downgrade to node v10.
Comment 2•2 years ago
|
||
This just bit mconley today too...
Comment 3•2 years ago
|
||
NI @dmosedale to help add more context on fix thanks
Updated•2 years ago
|
Comment 4•2 years ago
•
|
||
Proposed fix: edit package.json (and probably .nvmrc) to update to the current versions (node = 16.19.* and npm = 8.19.* ) with a bit of security version flex. I think we want to keep the versions specified pretty tightly because it generates artifacts that get checked in and we want those to be modern and identical across users. I propose node = 16.19.* and npm = 8.19.*
https://searchfox.org/mozilla-central/rev/af78418c4b5f2c8721d1a06486cf4cf0b33e1e8d/browser/components/newtab/package.json#63 has more details.
Assignee | ||
Updated•2 years ago
|
Comment 5•2 years ago
•
|
||
(And by "current version", I mean the versions that running ./mach bootstrap
currently causes to be installed in ./mach build
and then used by ./mach node
and ./mach npm
).
Assignee | ||
Comment 6•2 years ago
|
||
Updated•2 years ago
|
Updated•2 years ago
|
Comment 7•2 years ago
•
|
||
This ended up getting fixed in bug 1786582 (phab patch); sorry for the crossed wires, Negin!
Updated•2 years ago
|
Description
•