Skip to content

fix(release): check the version on main, not the one changesets/action just made - #208

Merged
dgesteves merged 2 commits into
mainfrom
fix/release-version-on-main
Oct 23, 2026
Merged

dgesteves merged 2 commits into
mainfrom
fix/release-version-on-main

Conversation

@dgesteves

@dgesteves dgesteves commented Oct 23, 2026 •

Copy link
Copy Markdown
Owner

The Release workflow has failed on every push to main with pending changesets since the check came in with #152 (Oct 16), for example run 38850596741 (named 0.8.1 while main had 0.8.0) and, most recently, the merge of #207:

signoff-ui@0.10.1 is the version on main, but npm doesn't have it and it has no tag, so it was never published.

0.10.1 is not the version on main (main has 0.10.0, which npm has). With pending changesets, changesets/action switches the checkout to changeset-release/main and versions the package there, so the "The version on main is on npm" step after it read the version pull request's 0.10.1 from package.json. The check could only pass on a push with no version bump pending.

What changed:

  • The release job reads the version on main in a new step before changesets/action (id: main) and passes it as VERSION to both check-published.mjs steps, as onsystem's release workflow does.
  • check-published.mjs uses VERSION when it is set, and packages/signoff-ui/package.json's version otherwise (the dry run, and local runs, are unchanged).
  • RELEASING.md, the step comments and the script's header say where the version comes from.

Tests: check-published.test.ts checks the version VERSION names over a bumped package.json, both when npm has it and when it doesn't (the error names main's version), and release-workflow.test.ts checks the step runs before changesets/action and feeds both checks. Both new tests fail on main and pass here. format:check, lint, build:lib and typecheck pass. No changeset: CI and scripts only.

…n just made

With pending changesets, changesets/action switches the checkout to
changeset-release/main and versions the package there, so the npm check
after it read the next version (0.10.1) from package.json and failed:
every push to main since #173 went red with "signoff-ui@0.10.1 ... was
never published". The release job now reads the version before
changesets/action runs and passes it to check-published.mjs as VERSION,
as onsystem's release workflow does.
@dgesteves
dgesteves merged commit 1cd299b into main Oct 23, 2026
13 checks passed
@dgesteves
dgesteves deleted the fix/release-version-on-main branch October 23, 2026 21:33
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.

1 participant