Skip to content

Standardise on Node 24 LTS across Docker, CI and engines - #121

Closed
rusahu wants to merge 1 commit into
mainfrom
ci/node-26
Closed

rusahu wants to merge 1 commit into
mainfrom
ci/node-26

Conversation

@rusahu

@rusahu rusahu commented Aug 3, 2026 •

Copy link
Copy Markdown
Owner

Node was pinned in four places with three different answers, and nobody chose any of them.

Where Was Now
Dockerfile ×3 26 (current line, not LTS) 24
.github/workflows/ci.yml ×2 20 24
engines >=18.0.0 >=24.0.0
local dev unpinned .nvmrc → 24

How it drifted

b56f9bc  2026-04-03  Bump node from 20-alpine to 25-alpine     <- Dependabot
5b3d0e4  2026-05-08  chore(deps): bump node 25-alpine -> 26    <- Dependabot

Dependabot manages the Dockerfile's FROM but cannot see setup-node in workflow YAML. So the shipped image marched 20 → 25 → 26 while CI stayed on 20 — meaning every check was validating a runtime we never deploy.

Why 24 and not 26

Web Storage was unflagged in Node 25 (nodejs/node#57666). From 25 onward, Node installs its own localStorage global that shadows jsdom's and is unusable without --localstorage-file — it throws on 25 and is undefined on 26 (nodejs/node#61333). Any test touching localStorage dies; a first attempt at this PR on Node 26 failed exactly that way in SetlistPlayView.test.tsx, and it is a known vitest issue (vitest-dev/vitest#8757).

Node 26 would have meant carrying execArgv: ['--no-webstorage'] in the vitest config indefinitely. Node 24 has no such problem, needs no workaround, and is LTS (Krypton). It also satisfies every dependency floor currently blocked: better-sqlite3 13 (>=22), jsdom 30 (^24.15.0), jest-dom 7 (>=22).

Docker node majors are now held back

Without this the change does not stick — Dependabot would bump straight back to 26 next week and re-split CI from production. Minor and patch updates still come through; the next LTS move becomes deliberate, updating all four places together.

Unblocks

#116 (better-sqlite3 13), #117 (jsdom 30) and #118 (jest-dom 7) all require Node ≥22 and were failing only because CI ran 20.

Note

engines now says >=24.0.0. Anyone developing locally on Node 22 will need to switch — .nvmrc is there for that.

- Dependabot walked the image 20 -> 25 -> 26 onto a non-LTS current line while CI stayed on 20 and engines still claimed >=18; pin all of them to 24 LTS and add .nvmrc so local dev matches
- Node 24 avoids the Web Storage default introduced in 25, which shadows jsdom's localStorage and breaks any test touching it
- Hold back Docker node majors so the next LTS move is deliberate rather than drifting back apart
@rusahu rusahu changed the title Run CI on Node 26 to match the Docker image Standardise on Node 24 LTS across Docker, CI and engines Aug 3, 2026
@rusahu

rusahu commented Aug 3, 2026

Copy link
Copy Markdown
Owner Author

Superseded by #122 — same change, branch renamed (this one said node-26 and scoped itself to CI, but the change covers Docker, engines and .nvmrc too).

@rusahu rusahu closed this Aug 3, 2026
@rusahu
rusahu deleted the ci/node-26 branch August 3, 2026 03:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant