Skip to content

Fix npm publish workflow prerelease ref handling - #85

Draft
NorthernMan54 with Copilot wants to merge 2 commits into
latestfrom
copilot/fix-publish-to-npm-job
Draft

Fix npm publish workflow prerelease ref handling#85
NorthernMan54 with Copilot wants to merge 2 commits into
latestfrom
copilot/fix-publish-to-npm-job

Conversation

Copilot AI commented Jul 30, 2026

Copy link
Copy Markdown

Changes Proposed in this Pull Request
The "Publish to npm" job failed in the Release workflow because prerelease versioning passedgithub.ref_name(e.g.beta-1.4.0) to npm-version-script.js, but that script expects a full Git ref (refs/heads/...`). This updates the workflow input so beta/alpha publish paths no longer trip the assertion and exit early.

  • Root cause

    • npm-version-script.js asserts ref.startsWith('refs/heads/').
    • Workflow passed ${{ github.ref_name }} instead of ${{ github.ref }}.
  • Workflow change

    • Updated prerelease versioning invocation in .github/workflows/release.yml to pass the full ref.
# before
node .github/npm-version-script.js ${{ github.ref_name }} ${{ steps.release-type.outputs.type }}

# after
node .github/npm-version-script.js ${{ github.ref }} ${{ steps.release-type.outputs.type }}

`

Copilot AI changed the title [WIP] Fix failing GitHub Actions job 'Publish to npm' Fix npm publish workflow prerelease ref handling Jul 30, 2026
Copilot AI requested a review from NorthernMan54 July 30, 2026 12:58
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.

2 participants