ci(release): fix dry-run gate broken by github.event_name in reusable workflows#172
Merged
Conversation
… workflows In a workflow_call'd workflow, github.event_name reports the parent trigger (workflow_dispatch from release-pipeline), not 'workflow_call'. So the previous condition github.event_name == 'workflow_call' always evaluated false, causing Dry-run summary to skip and Create GitHub release to run during dry-run dispatches — producing a real v0.25.0 tag and release with a placeholder body. Fix: gate on inputs.dry_run directly. Add dry_run input to the workflow_dispatch form so standalone dispatches can dry-run too.
This was referenced May 21, 2026
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.
Bug
The previous dry-run gate in
release.yamlwas:```yaml
if: github.event_name == 'workflow_call' && inputs.dry_run == true
if: ${{ !(github.event_name == 'workflow_call' && inputs.dry_run == true) }}
```
In a reusable workflow invoked via
workflow_call,github.event_nameis the parent trigger (here,workflow_dispatchfromrelease-pipeline.yaml), notworkflow_call. So the condition was always false:Dry-run summaryskipped,Create GitHub releaseran.The dry-run of run 26254656039 consequently created a real
v0.25.0tag and GH release with a placeholder body. The tag and release were manually cleaned up before this PR. PyPI publish, push-to-stable, and the bump commit were not affected — they correctly gate oninputs.dry_rundirectly.Fix
Gate on
inputs.dry_rundirectly. Also adddry_runto theworkflow_dispatchinput list so the standalone form supports dry-run too.Test plan
Release pipelinewithincrement=auto, dry_run=trueand confirmreleasestep showsDry-run summary✅ andCreate GitHub releaseskipped.