Skip to content

fix(ci): gate release workflow on successful test run - #81

Merged
erikarenhill merged 2 commits into
masterfrom
ci/gate-release-on-tests
Apr 17, 2026
Merged

erikarenhill merged 2 commits into
masterfrom
ci/gate-release-on-tests

Conversation

@erikarenhill

Copy link
Copy Markdown
Collaborator

semantic-release was racing go test + vet — both workflows triggered on push:master in parallel, so the changelog commit + tag push landed before the test job finished and GitHub's branch protection rejected it with GH006 ("Required status check 'go test + vet' is expected").

Switch release.yml's trigger to workflow_run on the test workflow and guard the semantic-release job with
conclusion == 'success'. workflow_dispatch stays wired for manual re-runs (event has no workflow_run payload — gate on event name too).

The downstream binaries + docker jobs already gate on needs.release.outputs.new_release_published, so no extra if: needed there.

erikarenhill and others added 2 commits April 17, 2026 12:04
semantic-release was racing `go test + vet` — both workflows triggered
on `push:master` in parallel, so the changelog commit + tag push landed
before the test job finished and GitHub's branch protection rejected
it with GH006 ("Required status check 'go test + vet' is expected").

Switch release.yml's trigger to `workflow_run` on the `test` workflow
and guard the semantic-release job with
`conclusion == 'success'`. `workflow_dispatch` stays wired for manual
re-runs (event has no `workflow_run` payload — gate on event name too).

The downstream `binaries` + `docker` jobs already gate on
`needs.release.outputs.new_release_published`, so no extra `if:` needed
there.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@erikarenhill
erikarenhill merged commit 1a659ad into master Apr 17, 2026
1 check passed
@erikarenhill
erikarenhill deleted the ci/gate-release-on-tests branch April 17, 2026 10: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