fix: explicitly trigger release.yml since GITHUB_TOKEN pushes can't - #4
Merged
Merged
Conversation
version-bump.yml pushes its release commit and vX.Y.Z tag using the default GITHUB_TOKEN. GitHub suppresses push-triggered workflow runs for GITHUB_TOKEN-authored pushes (anti-recursion protection), so release.yml never actually ran for those pushes even though the version bump, tag, and GitHub Release all succeeded — confirmed via the Actions run history after PR #3 merged (0.0.0 release.yml runs for the tag, only for real PR-merge commits). workflow_dispatch calls are exempt from that restriction, so version-bump.yml now explicitly runs `gh workflow run release.yml --ref vX.Y.Z` as its last step, and release.yml gained a workflow_dispatch trigger to accept it. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ST7p7inT3agkLEp8qbPSC6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
After #3 merged,
version-bump.ymlran successfully —package.jsonwas bumped to1.0.2, the commit andv1.0.2tag were pushed, and a GitHub Release was created — but no Docker image was published for it.Root cause:
version-bump.ymlpushes its release commit and tag using the defaultGITHUB_TOKEN. GitHub explicitly suppressespush-triggered workflow runs forGITHUB_TOKEN-authored pushes (anti-recursion protection). Confirmed via the Actions run history:release.ymlonly ran 3 times total, exactly matching the 3 real PR merges (#1, #2, #3) via the GitHub merge button — never for thechore(release)commit or thev1.0.2tag pushed by the bot.Fix:
workflow_dispatchcalls ARE exempt from that restriction. So:release.ymlgains aworkflow_dispatch:trigger.version-bump.yml's last step now runsgh workflow run release.yml --ref "vX.Y.Z"right after pushing the tag, explicitly kicking off the image build against that tag ref (sodocker/metadata-action's semver tag derivation still works exactly as it does for a real tag push).permissions.actions: writeadded so the bot token is allowed to dispatch the workflow.Docs updated to reflect the explicit-dispatch step.
Test plan
version-bump.ymlbumps to1.0.3, tagsv1.0.3, and its "Trigger Docker image build" step succeeds — then confirm arelease.ymlrun actually appears (triggered byworkflow_dispatch) and publishesghcr.io/veniplex/study-helper:1.0.3,:1.0,:1,:latest.Generated by Claude Code