Upgrade Node.js to v22 in CI workflows#882
Conversation
Co-authored-by: willtheorangeguy <18339050+willtheorangeguy@users.noreply.github.com> Agent-Logs-Url: https://github.com/willtheorangeguy/willtheorangeguy.github.io/sessions/5a4397b7-d692-4263-b968-4afc5e28e831
There was a problem hiding this comment.
Pull request overview
Updates GitHub Actions workflows to use Node.js 22 to restore compatibility with Astro v6 (which no longer supports Node.js < 22.12.0) and unblock the GitHub Pages build.
Changes:
- Bumped Node.js version in the Astro Pages deployment workflow from 20 → 22.
- Bumped Node.js version in the Google Maps stats update workflow from 20 → 22.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
.github/workflows/astro.yml |
Updates Node.js version used for the Astro build/deploy job. |
.github/workflows/update-google-maps-stats.yml |
Updates Node.js version used for the scheduled stats update job. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| uses: actions/setup-node@v6 | ||
| with: | ||
| node-version: "20" | ||
| node-version: "22" |
There was a problem hiding this comment.
Astro v6 requires Node.js >= 22.12.0 (per PR description). node-version: "22" only pins the major and can resolve to an earlier 22.x release depending on what setup-node selects, which could reintroduce the build failure. Consider pinning to at least 22.12.0 (or 22.12.x) to enforce the minimum supported version deterministically.
| node-version: "22" | |
| node-version: "22.12.0" |
| uses: actions/setup-node@v6 | ||
| with: | ||
| node-version: '20' | ||
| node-version: '22' |
There was a problem hiding this comment.
Astro v6 requires Node.js >= 22.12.0 (per PR description). node-version: '22' only pins the major and may resolve to an earlier 22.x release, which could break scripts if they assume the minimum supported version. Consider pinning to 22.12.0 (or 22.12.x) here as well for deterministic workflow behavior.
| node-version: '22' | |
| node-version: '22.12.0' |
Astro v6 dropped support for Node.js <22.12.0, causing the GitHub Pages build to fail on the previously pinned v20 runner.
Changes
.github/workflows/astro.yml—node-version: "20"→"22".github/workflows/update-google-maps-stats.yml—node-version: '20'→'22'