fix(release): drop pnpm version pin from npm-publish.yml — packageManager wins#25
Merged
Merged
Conversation
…ager wins The first workflow_dispatch run of npm-publish.yml on the v0.1.0 release (https://github.com/bitrix24/b24rabbitmq/actions/runs/26621673812) failed at the `Install pnpm` step: Error: Multiple versions of pnpm specified: - version 10 in the GitHub Action config with the key "version" - version pnpm@10.10.0 in the package.json with the key "packageManager" Remove one of these versions to avoid version mismatch errors like ERR_PNPM_BAD_PM_VERSION The explicit `version: 10` on `pnpm/action-setup@v4` was added in PR #18 on a senior-dev review suggestion to make the pin "consistent with packageManager". On the pnpm/action-setup version current at runtime, that's now ambiguous — the action wants one source of truth. Keep `packageManager: pnpm@10.10.0` (more precise, already canonical for `corepack`, `pnpm install` locally, and every other tool that reads it). Drop the workflow `version:` input. Same pattern already used in ci.yml. Also confirms the Node 24 opt-in from PR #23 is working: the same run logs `Node.js 20 is deprecated. The following actions target Node.js 20 but are being forced to run on Node.js 24: actions/checkout@v4, pnpm/action-setup@v4` — exactly the intended behaviour of FORCE_JAVASCRIPT_ACTIONS_TO_NODE24. Post-merge: re-trigger npm-publish.yml via workflow_dispatch. Gates: lint, typecheck, test (66/66) all green.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Second blocker on the v0.1.0 publish path. Tiny fix.
The failure
workflow_dispatchrun on the v0.1.0 tag failed at theInstall pnpmstep:The explicit
version: 10onpnpm/action-setup@v4was added in PR #18 on a senior-dev review nit ("make the pin consistent with packageManager"). On the action version current at runtime, two sources of truth is no longer accepted — the action wants one.The fix
Drop
version: 10from the workflow. Letpnpm/action-setup@v4readpackageManager: pnpm@10.10.0frompackage.jsondirectly (more precise, already authoritative for corepack, local installs, and every other tool). Same shape used inci.yml, which doesn't see this error.Bonus confirmation: Node 24 opt-in is working
The same failed run logs:
That's exactly the intended behaviour of the
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=trueflag added in PR #23. Notice this is an informational message, not an error — Node 24 enforcement is in place.Post-merge plan
Re-trigger
npm-publish.ymlviaworkflow_dispatchonmain. Expected progression:Install pnpm— now picks uppnpm@10.10.0frompackageManager, single source of truth.Install node— Node 22 with npm registry config.Install dependencies—pnpm install --frozen-lockfile.Upgrade npm CLI for OIDC trusted publishing—npm install -g 'npm@^11.5.1'.Sanity check — tag matches package.json version—b24rabbitmq-v0.1.0(the existing tag) → strip →0.1.0→ matchespackage.json.Lint/Typecheck/Test/Build/Docs (TypeDoc dry-run).Publish 🚀 (OIDC trusted publishing)— exchanges OIDC token for one-shot npm credential →npm publish --provenance→@bitrix24/b24rabbitmq@0.1.0lands on npm.Gates
pnpm lintpnpm testNo
src/changes. Workflow-only.Generated by Claude Code