Skip to content

ci: report Build & canary release once, and skip the canary on release PRs - #1264

Merged
tenphi merged 2 commits into
mainfrom
ci-tidy-release-checks
Jul 29, 2026
Merged

ci: report Build & canary release once, and skip the canary on release PRs#1264
tenphi merged 2 commits into
mainfrom
ci-tidy-release-checks

Conversation

@tenphi

@tenphi tenphi commented Jul 29, 2026

Copy link
Copy Markdown
Member

Describe changes

Two leftovers in the release config, both visible now that the Version Packages PR actually runs the required workflows (#1262).

1. Build & canary release was reported twice

Two jobs published the same check name:

Workflow Job What it did
pull-request.yml build-canary-status echo "Canary publishing is handled by publish.yml" — 3 seconds, builds nothing
publish.yml publish-canary the real build + canary publish

Both appeared on every PR (visible on #1263), and since branch protection matches by name, the requirement could be satisfied by whichever reported first — including the no-op. Removed the no-op so the real job carries the name.

Both workflows share the same paths-ignore (.changeset/**, .husky/**), so which PRs receive the check is unchanged by this.

2. The canary published on the Version Packages PR

publish-canary was gated only on github.event_name == 'pull_request', so the release PR got a canary too — despite its diff being nothing but a version bump and changelog. That published a duplicate of what main had just released and left another stale pr_* dist-tag behind. Those tags accumulate: npm dist-tag ls @cube-dev/ui-kit currently lists pr_69, pr_70, pr_72, … going back years.

The publish and PR-comment steps are now guarded with github.head_ref != 'changeset-release/main'.

Deliberately guarding the steps, not the job. Skipping the whole job would stop Build & canary release from reporting, which would block the release PR — the exact problem #1262 just fixed. This way the job still runs, the required check still reports, and pnpm build still verifies the precise tree that is about to ship.

Verification

This PR carries a changeset on purpose, so merging it exercises the full path end to end. What I'll check on the resulting Version Packages PR:

  • exactly one Build & canary release check, not two
  • all four required checks present and green
  • no new pr_* dist-tag created for the release PR
  • merges via normal auto-merge, no admin override

Not included

Pruning the existing stale pr_* dist-tags is a separate cleanup — it mutates published npm metadata rather than CI config, so it doesn't belong in the same change.

Checklist
  • Pipeline is passed
  • Tests are added — n/a, CI configuration only
  • Tests are passed successfully
  • If you're adding a new component/new props, add stories — n/a
  • Changeset(s) is(are) added — patch, and intentionally so: it exercises the release flow this PR changes
  • Commit message follows commit guidelines

Closes: N/A

Other information

No runtime or published-code changes; the version bump exists to verify the pipeline.

🤖 Generated with Claude Code


Note

Low Risk
Workflow-only changes with no application code; the release PR still runs build and reports the required check.

Overview
CI-only release pipeline fixes so branch protection and npm tags behave correctly on normal and Version Packages PRs.

pull-request.yml drops the no-op build-canary-status job that echoed a placeholder while publish.yml’s publish-canary job already reports the same Build & canary release check name—so PRs get a single real check instead of two identically named ones.

publish.yml adds if: github.head_ref != 'changeset-release/main' on Publish canary to npm and Comment PR only. The publish-canary job still runs (build + check) on the changeset release branch; it just skips redundant npm publish and the canary comment that would duplicate main and add another stale pr_* dist-tag.

A patch changeset documents the maintenance release with no runtime code changes.

Reviewed by Cursor Bugbot for commit db03b3b. Bugbot is set up for automated code reviews on this repo. Configure here.

…e PRs

Two leftovers in the release config, both surfaced now that the Version
Packages PR actually runs the required workflows.

`Build & canary release` was reported twice under the same context name: a
three-second no-op in pull-request.yml and the real build in publish.yml.
Branch protection could therefore be satisfied by whichever reported first,
including the no-op that builds nothing. Remove the no-op; the real job in
publish.yml carries the name. Both workflows share the same `paths-ignore`, so
which PRs get the check is unchanged.

The canary publish also ran on the Version Packages PR, whose diff is only a
version bump and changelog — so it published a duplicate of what main had just
released and left another stale `pr_*` dist-tag behind. Guard the publish and
PR-comment steps on the release branch. The job still runs, so the required
check reports and the build still verifies the exact tree about to ship.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Jul 29, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cube-ui-kit Ready Ready Preview, Comment Jul 29, 2026 1:29pm

Request Review

@changeset-bot

changeset-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: db03b3b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@cube-dev/ui-kit Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions

github-actions Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

📦 NPM canary release

Deployed canary version 0.0.0-canary-a103318.

@github-actions

github-actions Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

🧪 Storybook is successfully deployed!

@github-actions

Copy link
Copy Markdown
Contributor

🏋️ Size limit report

Name Size Passed?
All 434.03 KB (0% 🟰) Yes 🎉
Tree shaking (just a Button) 114.87 KB (0% 🟰) Yes 🎉

Click here if you want to find out what is changed in this build

@tenphi
tenphi enabled auto-merge (squash) July 29, 2026 13:28
@tenphi
tenphi merged commit 351a175 into main Jul 29, 2026
15 checks passed
@tenphi
tenphi deleted the ci-tidy-release-checks branch July 29, 2026 13:30
@tenphi tenphi mentioned this pull request Jul 29, 2026
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