Skip to content

Release: stand down when main moved on with changed workflows - #79

Merged
Maxaubert merged 1 commit into
mainfrom
fix/release-skip-stale-workflow
Sep 28, 2026
Merged

Maxaubert merged 1 commit into
mainfrom
fix/release-skip-stale-workflow

Conversation

@Maxaubert

Copy link
Copy Markdown
Owner

v0.18.5's release run (#76) failed at Publish with HTTP 403: Resource not accessible by integration. #78 changed release.yml and merged 49 s before that step. GitHub won't let the workflow token create a tag on a commit whose workflow files differ from main's; that needs a workflows permission the token can't be given. The --target pinning from the code review (#11) makes this reachable. Nothing was lost: the next run, on #78's merge commit, published v0.18.5, and that commit contains #76.

The fix: before gh release create, fetch main. If main has moved on AND its workflows differ from the built commit's, the run stands down with a notice, and the next run publishes the version (runs queue one at a time, so it starts after this one). In every other case the tag still goes on the built commit.

Verification: YAML parses. The diff test was checked on the real commits: 7b9e13d against d634dec means stand down (exit 1), and d634dec against main means publish (exit 0). Workflow change only, so no version bump.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LJbePcRzre7AusNzPNS2Bk

…lows

GitHub refuses the workflow token a tag on a commit whose workflows differ
from main's (HTTP 403, measured on v0.18.5's run, 49 s after a workflow
change merged). The next run on main publishes that version, as it did.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LJbePcRzre7AusNzPNS2Bk
@Maxaubert
Maxaubert merged commit 7ab0726 into main Sep 28, 2026
2 checks passed
@Maxaubert
Maxaubert deleted the fix/release-skip-stale-workflow branch September 28, 2026 14:40
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