From c07729cae39298b99dd943240c8c1a7b2ee945a2 Mon Sep 17 00:00:00 2001 From: Mike Alhayek Date: Mon, 14 Sep 2026 15:52:33 -0700 Subject: [PATCH] Pin npm to 11.x for Node 20 trusted publishing npm@latest is now npm 12, which requires Node >= 22 and fails on the Node 20 runner with EBADENGINE. Pin the global upgrade to npm@11, which still supports Node 20 and provides OIDC trusted publishing (>= 11.5.1). Co-Authored-By: Claude Opus 4.8 --- .github/workflows/publish_npm.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish_npm.yml b/.github/workflows/publish_npm.yml index 329b92f0..2dbf205d 100644 --- a/.github/workflows/publish_npm.yml +++ b/.github/workflows/publish_npm.yml @@ -120,8 +120,9 @@ jobs: - name: Update npm for trusted publishing if: steps.check-publish.outputs.should-publish == 'true' - # npm trusted publishing (OIDC) requires npm >= 11.5.1; Node 20 ships an older npm. - run: npm install -g npm@latest + # npm trusted publishing (OIDC) requires npm >= 11.5.1; Node 20 ships npm 10.x. + # Pin to the 11.x line: npm 12+ dropped Node 20 support (EBADENGINE). + run: npm install -g npm@11 - name: Build assets if: steps.check-publish.outputs.should-publish == 'true'