Skip to content

chore(node): drop Node 20, add Node 26; refactor puppeteer image#293

Open
vladfrangu wants to merge 7 commits into
masterfrom
vlad-cc/update-node-versions
Open

chore(node): drop Node 20, add Node 26; refactor puppeteer image#293
vladfrangu wants to merge 7 commits into
masterfrom
vlad-cc/update-node-versions

Conversation

@vladfrangu
Copy link
Copy Markdown
Member

@vladfrangu vladfrangu commented May 15, 2026

Summary

  • Drop Node 20 (EOL April 2026) and add Node 26 to supportedNodeVersions
  • Refactor the node-puppeteer-chrome image to mirror the playwright image's browser-install pattern:
    • Pre-install chrome and chrome-headless-shell into PUPPETEER_CACHE_DIR=/puppeteer-browsers during the system-deps step
    • Set PUPPETEER_SKIP_DOWNLOAD / PUPPETEER_SKIP_CHROMIUM_DOWNLOAD so the user-stage npm install doesn't re-download
    • Pin npx puppeteer@${PUPPETEER_VERSION} so each image's Chrome revision matches the runtime puppeteer's expected revision (workflow passes PUPPETEER_VERSION as a build-arg)
    • unzip is purged after browser extraction (it was being purged before, which broke puppeteer 25's chrome-headless-shell install)

Test plan

  • Local: built and ran the puppeteer-chrome image against all 5 matrix versions (24.41.0, 24.42.0, 24.43.0, 24.43.1, 25.0.2) — all pass test PASSED
  • CI: green on all node × puppeteer combinations

@github-actions github-actions Bot added this to the 140th sprint - Tooling team milestone May 15, 2026
@github-actions github-actions Bot added the t-tooling Issues with this label are in the ownership of the tooling team. label May 15, 2026
@vladfrangu vladfrangu added the adhoc Ad-hoc unplanned task added during the sprint. label May 15, 2026
@vladfrangu vladfrangu requested a review from B4nan May 15, 2026 19:06
…er install

Puppeteer 25 renamed PUPPETEER_SKIP_CHROMIUM_DOWNLOAD to PUPPETEER_SKIP_DOWNLOAD
and its installer now requires unzip to extract chrome-headless-shell. Since we
already provide system Chrome, skip the download entirely.
Mirrors the playwright image setup: declare PUPPETEER_CACHE_DIR, pre-install
chrome + chrome-headless-shell during the system-deps RUN, then set
PUPPETEER_SKIP_DOWNLOAD so the user-stage npm install doesn't re-download.

The install command is pinned via `npx puppeteer@${PUPPETEER_VERSION}` so the
Chrome revision baked into the image matches the runtime puppeteer's
expected revision. The workflow now passes PUPPETEER_VERSION as a build-arg.

Verified locally against all 5 matrix versions (24.41.0..25.0.2).
@vladfrangu vladfrangu changed the title chore(node): drop Node 20, add Node 26 to supported versions chore(node): drop Node 20, add Node 26; refactor puppeteer image May 15, 2026
@vladfrangu vladfrangu requested a review from Copilot May 16, 2026 09:36
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Node/Puppeteer image matrix and refactors the Puppeteer Chrome Docker image to preinstall Puppeteer-managed browser revisions during image build.

Changes:

  • Updates supported Node versions from 20/22/24 to 22/24/26.
  • Adds PUPPETEER_VERSION as a Docker build argument in the Puppeteer workflow.
  • Refactors node-puppeteer-chrome browser installation and related environment variables.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
node-puppeteer-chrome/Dockerfile Adds Puppeteer browser preinstallation and moves related environment configuration earlier in the image build.
.github/workflows/release-node-puppeteer.yaml Passes the Puppeteer version into Docker builds as a build argument.
.github/actions/version-matrix/src/shared/constants.ts Replaces Node 20 with Node 26 in the supported Node matrix.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread node-puppeteer-chrome/Dockerfile Outdated
Older puppeteer versions (24.x) bundle @puppeteer/browsers 2.13.0, which
silently fails to extract Chrome on node 26 — the extraction reports success
but the actual chrome binary is missing from the cache, so the runtime
puppeteer can't find its expected revision.

Read the pinned Chrome revisions from puppeteer-core@${PUPPETEER_VERSION}'s
revisions.js (parsed as text to support both CJS in 24.x and ESM in 25.x),
then invoke @puppeteer/browsers@3.0.2 directly to perform the actual install.
Copy link
Copy Markdown
Member

@B4nan B4nan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lets merge on monday and announce it on slack.

@vladfrangu
Copy link
Copy Markdown
Member Author

Still fixing some things on node 26, but after that works and alpha tag builds, we can do the monday release

Read PUPPETEER_REVISIONS through puppeteer-core's public ESM export
instead of find+grep+sed on internal revisions.js. Collapse the two
node invocations into one (parsed with bash `read`). Drop the
@puppeteer/browsers@3.0.2 pin so the install picks up the latest CLI.

Pass PUPPETEER_VERSION as a build arg in the Makefile puppeteer targets,
matching the new Dockerfile contract.
@vladfrangu
Copy link
Copy Markdown
Member Author

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants