Repository navigation
ci: bump Node 20 → 24 in workflows - #401
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #401 +/- ##
=======================================
Coverage ? 47.75%
=======================================
Files ? 2
Lines ? 423
Branches ? 0
=======================================
Hits ? 202
Misses ? 221
Partials ? 0
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
This PR updates the GitHub Actions workflows to run on Node.js 24 instead of Node.js 20, keeping CI on a supported runtime and aligning better with the updated npm toolchain requirements introduced in #400.
Changes:
- Bump
actions/setup-nodenode-versionfrom20to24in CI, docs deploy, and snapshot update workflows. - Document the CI Node bump in the Unreleased changelog.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
CHANGELOG.md |
Notes the CI runtime bump from Node 20 to Node 24 under Unreleased CI changes. |
.github/workflows/ci.yml |
Runs visual regression job setup on Node 24. |
.github/workflows/docs.yml |
Builds documentation assets on Node 24. |
.github/workflows/update-snapshots.yml |
Runs snapshot update jobs on Node 24. |
🎭 Visual Regression Test ResultsDetails
Skipped testsdesktop-chrome › theme.spec.ts › Visual Regression Tests › prob-matrix - full page screenshot |
Node 20 reached EOL in April 2026, and the npm toolchain updates in PR #400 raised engine floors (sass-loader 17 declares node >=22.11). Node 24 is the current active LTS, supported until April 2028. Co-Authored-By: Claude Fable 5 <[email protected]>
Addresses Copilot review on #401: CI moving to Node 24 while .nvmrc pinned 20.18.0 would leave contributors on a runtime below the toolchain's engine floors (sass-loader 17 declares node >=22.11). .nvmrc now reads 24 (resolves to latest 24.x), and CONTRIBUTING.md / docs/developer/setup.md prerequisites say Node 24 or newer. Co-Authored-By: Claude Fable 5 <[email protected]>
* build: compile theme assets on Node 24 sphinx-theme-builder installs the Node pinned in pyproject.toml ([tool.sphinx-theme-builder] node-version) into .nodeenv/ and uses it for npm install and webpack in every wheel build: the PyPI release in tests.yml, the CI and docs installs, and local installs. That pin was still 20.18.0 after #401 moved setup-node and .nvmrc to Node 24, so the shipped assets were still compiled on Node 20. Move the pin to 24.21.0, the current Node 24 LTS (Krypton), the same pin QuantEcon/quantecon-sphinx-theme#9 set. .nvmrc moves from "24" to the same exact version, as that repository did, so nvm gives local development the Node the build uses. sphinx-theme-builder refuses a nodeenv whose node --version differs from the pin, so the two pins cannot drift silently in the build, only in .nvmrc. Built locally with python -m build and pip wheel . on both pins, the wheels' contents are identical, compiled CSS, JS and source maps included. The seven npm EBADENGINE warnings the Node 20.18.0 install printed (sass-loader 17 wants >= 22.11.0, among others) are gone. The troubleshooting example in docs/developer/setup.md now shows the mismatch error an existing .nodeenv/ will raise after this change. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> * docs(changelog): name the two costs of the Node 24 pin A source build now needs a platform nodejs.org ships a Node 24 binary for, which excludes linux-armv7l and 32-bit Windows (both have Node 20.18.0 builds, neither has 24.21.0); the py3-none-any wheel is unaffected. And with .nvmrc pinned exactly, nvm use needs one nvm install per bump. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
Summary
Bumps
node-versionfrom'20'to'24'inci.yml,docs.yml, andupdate-snapshots.yml(4 occurrences).Why
sass-loader17 declaresnode >=22.11, andsass1.100 /chokidar5 require ≥20.19. CI on Node 20 only passed because npm treats engine mismatches as warnings — we were building outside the toolchain's supported range.Verification
CI on this PR exercises the full post-#400 toolchain (webpack 5.107, webpack-cli 7, sass-loader 17, Playwright 1.60) on Node 24 — the
buildandvisualjobs passing is the validation.🤖 Generated with Claude Code