Skip to content

ci(release): attach assets to the CLI v<version> tag, not releases[0]#18

Merged
JonathanTurnock merged 1 commit into
mainfrom
fix/release-assets-cli-tag
Jun 3, 2026
Merged

ci(release): attach assets to the CLI v<version> tag, not releases[0]#18
JonathanTurnock merged 1 commit into
mainfrom
fix/release-assets-cli-tag

Conversation

@JonathanTurnock
Copy link
Copy Markdown
Collaborator

Why

The release run after the v0.1.0 release-PR merge had every asset build fail at actions/checkout (Windows, Linux, aarch64-macOS), and the Intel-macOS job sat queued. Not a build/compile problem and not my feature code — the jobs were handed ref: pseudoscript-layout-v0.1.0, which is not a git tag (the only tag is the CLI's v0.1.0).

release.yml passed fromJSON(release.outputs.releases)[0].tag. The version-bump PR touches the library crates too, so release-plz's releases array is order-dependent and [0] landed on the pseudoscript-layout entry, not the pseudoscript CLI. checkout then couldn't fetch that ref → all builds died before compiling. publish (needs: build) never ran, so no assets attached.

Fix

Resolve the CLI release tag explicitly by its v prefix (libraries would carry a <crate>-v… name; the CLI's git_tag_name is v{{version}} per release-plz.toml) and gate assets on it being non-empty (skips cleanly when nothing was released).

tag=$(jq -r 'map(select(.tag | startswith("v"))) | .[0].tag // empty' <<<"${RELEASES:-[]}")

Not changed

  • The macOS matrix is left intact. aarch64-apple-darwin (macos-latest) got a runner and only failed on the same checkout bug; x86_64-apple-darwin (macos-13, Intel) just waits longer in the scarcer macOS queue (it was cancelled when the stuck run was killed, not a failure). install.sh advertises the Intel-mac asset, so the target stays.

Verified

YAML parses; jq filter picks the CLI v… tag over a library entry and returns empty (→ skips assets) on empty input.

Recovery for the current v0.1.0 release

After merge, attach binaries to the existing tag by hand:
gh workflow run release-assets.yml -f tag=v0.1.0

🤖 Generated with Claude Code

The release-assets matrix builds all failed at `actions/checkout`: it was handed
`ref: pseudoscript-layout-v0.1.0` (a library entry), which is not a git tag — the
only tag is the CLI's `v0.1.0`. `release.yml` passed `releases[0].tag`, but the
version-bump PR touches the library crates too, so release-plz's `releases` array
is order-dependent and [0] landed on a library.

Resolve the CLI tag explicitly by its `v` prefix (libraries carry a `<crate>-v…`
name) and gate `assets` on it being non-empty. Now every target checks out the
real tag and builds. The macOS-Intel (`macos-13`) target is unaffected — it just
waits longer in the scarcer macOS queue.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Jun 3, 2026

Deploying pseudoscript-ide with  Cloudflare Pages  Cloudflare Pages

Latest commit: 1778a89
Status: ✅  Deploy successful!
Preview URL: https://e14dcc2a.pseudoscript-ide.pages.dev
Branch Preview URL: https://fix-release-assets-cli-tag.pseudoscript-ide.pages.dev

View logs

@cloudflare-workers-and-pages
Copy link
Copy Markdown

Deploying pseudoscript-landing with  Cloudflare Pages  Cloudflare Pages

Latest commit: 1778a89
Status: ✅  Deploy successful!
Preview URL: https://8b38a259.pseudoscript-landing.pages.dev
Branch Preview URL: https://fix-release-assets-cli-tag.pseudoscript-landing.pages.dev

View logs

@JonathanTurnock JonathanTurnock merged commit f68086a into main Jun 3, 2026
5 checks passed
@JonathanTurnock JonathanTurnock deleted the fix/release-assets-cli-tag branch June 3, 2026 07:11
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