From 13d828d236c05ac1a72570cf49a67b69b28bc139 Mon Sep 17 00:00:00 2001 From: Ahmed Ibrahim Date: Fri, 3 Apr 2026 19:26:41 -0700 Subject: [PATCH] Use Node 24 for npm publish (#16755) Avoid self-upgrading the runner's bundled npm in release publishing; Node 24 already provides an npm CLI that supports trusted publishing. Co-authored-by: Codex --- .github/workflows/rust-release.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/rust-release.yml b/.github/workflows/rust-release.yml index 37dd9f34f..30e16c417 100644 --- a/.github/workflows/rust-release.yml +++ b/.github/workflows/rust-release.yml @@ -584,14 +584,11 @@ jobs: - name: Setup Node.js uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6 with: - node-version: 22 + # Node 24 bundles npm >= 11.5.1, which trusted publishing requires. + node-version: 24 registry-url: "https://registry.npmjs.org" scope: "@openai" - # Trusted publishing requires npm CLI version 11.5.1 or later. - - name: Update npm - run: npm install -g npm@latest - - name: Download npm tarballs from release env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}