Skip to content

ci: run on Node 22 instead of end-of-life Node 18 - #137

Closed
rabi-siddique wants to merge 1 commit into
mainfrom
rabi/ago-1704-ui-kit-ci-runs-end-of-life-node-18
Closed

rabi-siddique wants to merge 1 commit into
mainfrom
rabi/ago-1704-ui-kit-ci-runs-end-of-life-node-18

Conversation

@rabi-siddique

Copy link
Copy Markdown

refs: AGO-1704

Description

CI runs on Node 18, which has been end-of-life since 2025-04 and gets no security fixes. That includes the canary job in trunk.yml, which publishes to npm using NPM_TOKEN. This PR moves CI to Node 22.

  • ci.yml and trunk.yml: node-version: 22 with check-latest: true, so CI always installs the newest 22.x patch instead of the version cached on the runner. Before this, ci.yml used whatever Node came with ubuntu-latest.
  • packages/react-components/.nvmrc: 22.

Two dependency fixes were needed for Node 22:

  • packages/rpc: the @endo/init dev dependency goes from ^0.5.60 to ^1.1.13. The old version bundles SES 0.18, whose lockdown() throws Accessor not expected at intrinsics.%IteratorPrototype%.constructor on Node 22, so test/marshal.test.ts failed.
  • Root package.json: dependenciesMeta skips building better-sqlite3 8.7.0.
    • It only comes in indirectly, through old @agoric/* packages (@agoric/swing-store).
    • Nothing here uses SQLite, and its native build fails on Node 22.
    • This setting only affects installs of this repo, not the published packages.

I didn't use Node 24 because better-sqlite3 8.7.0 doesn't build on it either. Getting to 24 would mean upgrading the old @agoric/* dependencies.

Security Considerations

This moves CI, including the npm-publishing job, off a Node line that no longer gets security fixes.

Scaling Considerations

None.

Documentation Considerations

None. Published packages are unchanged, apart from the dev dependency bump in rpc.

Testing Considerations

I ran the CI steps locally on Node 22.23.5, after a clean yarn install --immutable:

  • prepack, lint, docs and format all pass;
  • tests: all 10 test files pass.

Side note, out of scope here: yarn format --check runs prettier --write packages --check, so CI fixes formatting instead of failing on it. Two files in packages/example are unformatted on main.

- ci.yml and trunk.yml: node-version 22 with check-latest, so CI gets the newest 22.x patch. Node 18 is end-of-life since 2025-04.
- react-components .nvmrc: 22.
- rpc: bump the @endo/init dev dependency to ^1.1.13. The old one bundles SES 0.18, whose lockdown throws on Node 22's Iterator helpers.
- Root: skip building better-sqlite3 8.7.0. It only comes in through old @Agoric packages (via @agoric/swing-store), nothing here uses SQLite, and its native build fails on Node 22.

Refs: AGO-1704
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying ui-kit with  Cloudflare Pages  Cloudflare Pages

Latest commit: 49d2ce2
Status: ✅  Deploy successful!
Preview URL: https://ca02d76e.ui-kit-dwm.pages.dev
Branch Preview URL: https://rabi-ago-1704-ui-kit-ci-runs.ui-kit-dwm.pages.dev

View logs

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