Skip to content

fix: read the tag annotation checkout has not yet clobbered - #64

Merged
aicayzer merged 1 commit into
mainfrom
fix/release-tag-annotation
Sep 4, 2026
Merged

fix: read the tag annotation checkout has not yet clobbered#64
aicayzer merged 1 commit into
mainfrom
fix/release-tag-annotation

Conversation

@aicayzer

@aicayzer aicayzer commented Sep 4, 2026

Copy link
Copy Markdown
Owner

Closes #63.

actions/checkout force-updates refs/tags/<tag> to the commit after fetching the real tag, so both jobs that read the annotation were reading a lightweight tag.

verify refused v0.10.4 on its first real use. The quieter half is that release would have published feat: cut a release by pushing an annotated tag (#62) as the notes — the guard against exactly that was defeated by the same mechanism.

Fix is a re-fetch of the tag ref in both jobs. Reproduced and verified against a clean clone: commit after simulating checkout's second fetch, tag with the right annotation after the re-fetch.

actions/checkout fetches the annotated tag and then force-updates
refs/tags/<tag> to the commit it checks out, leaving a lightweight tag. Both
jobs that read the annotation read it after that, so verify refused every tag
and the release notes would have been the commit message.

The second is the failure that matters. Refusing a lightweight tag exists
precisely because for-each-ref falls through to the commit message on one,
and the guard was defeated by the same mechanism it guards against. Only the
loud failure stopped it publishing.

Both jobs now fetch the tag ref back before trusting it. fetch-depth: 0 does
not help, because checkout's second fetch runs regardless.
@aicayzer
aicayzer merged commit 6b2a92c into main Sep 4, 2026
2 checks passed
@aicayzer
aicayzer deleted the fix/release-tag-annotation branch September 4, 2026 10:48
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.

release workflow reads a tag annotation that checkout has already clobbered

1 participant