rollup.js (used in GrowthExperiments for bundling a lightweight version of d3) requires npm 8+, Fresh currently has npm 7 (Node.js v16.19.1 (npm 7.21.0)).
Description
Details
| Subject | Repo | Branch | Lines +/- | |
|---|---|---|---|---|
| update fresh-node16, add fresh-node18, add fresh-node20 | fresh | master | +462 -2 |
| Status | Subtype | Assigned | Task | ||
|---|---|---|---|---|---|
| Resolved | Feature | Krinkle | T337647 Add Fresh support for Node.js 18 (with npm 9) | ||
| Resolved | Jdforrester-WMF | T331181 Create WMF CI images and jobs for Node.js 18 |
Event Timeline
Can be worked around by using
fresh-node -- npm install -g --prefix ./custom-npm npm
and then writing custom-npm/bin/npm instead of npm but it's somewhat annoying.
Fresh follows WMF CI. WMF CI is meant to follow upstream Node.js packages, of which the npm pairings can be found at https://nodejs.org/en/download/releases.
We used to maintain a custom package for npm but I stopped doing that at npm version 7.21, with the idea to follow upstream instead.
When we upgraded CI from Node 12 to Node 14, we re-activated our package override to prevent a messy downgrade because upstream Node.js 14 shipped with npm 6, and our custom package was already ahead at npm version 7. I left a comment in the code so that when we upgrade CI to Node.js 16, we don't continue this override.
node14: Update from bundled npm 6 to pinned npm 7
https://gerrit.wikimedia.org/r/c/integration/config/+/723256
T267888, T267889
When the Node 16 upgrade took place for CI last year (https://gerrit.wikimedia.org/r/c/integration/config/+/813930), however, we kept the override. @Jdforrester-WMF found that the npm/npx commands from upstream were "non-operable".
Note that @kostajh reported the same rollup.js requirement with npm 8 at T314470#8636102. And WMDE has also reported this in relation to another packate at T330380.
I suggest we repurpose this task in favour of following T331181: Create WMF CI images and jobs for Node.js 18, and make sure to actually remove the override there in favour of Node.js 18's bundled npm package, which will be npm 9.
Change 946991 had a related patch set uploaded (by Krinkle; author: Krinkle):
[fresh@master] update fresh-node16, add fresh-node18, add fresh-node20
Change 946991 merged by jenkins-bot:
[fresh@master] update fresh-node16, add fresh-node18, add fresh-node20