Skip to content

fix(ci): release workflow dispatches release-announcement (#106)#107

Merged
millerjp merged 1 commit into
mainfrom
fix/ci-release-dispatch-announcement
May 17, 2026
Merged

fix(ci): release workflow dispatches release-announcement (#106)#107
millerjp merged 1 commit into
mainfrom
fix/ci-release-dispatch-announcement

Conversation

@millerjp
Copy link
Copy Markdown
Contributor

Fixes #106. Adds workflow_dispatch path to release-announcement.yml + dispatch step in release.yml so v1.0.3+ auto-announces. Governance tests updated.

Closes #106.

GitHub does not propagate `release: published` events to downstream
workflows when the release is created by another workflow using the
default GITHUB_TOKEN (anti-infinite-loop guard). This caused the
release-announcement workflow to never fire on v1.0.1 and v1.0.2 -
both had to be posted manually via `gh api graphql createDiscussion`.

Fix:

- release-announcement.yml: add `workflow_dispatch` trigger with a
  required `tag` string input. Body construction branches on
  `github.event_name` - when dispatched, fetch the release body
  via `gh release view` rather than reading the (absent) release
  event payload. Prerelease/draft filter still applies on the
  release event path; on dispatch the operator owns the decision.
- release.yml: new final job `announce` (needs: goreleaser, skipped
  on dry_run and on prerelease tags) that invokes
  `gh workflow run release-announcement.yml -f tag=...`. Job
  declares `actions: write` per-job because `workflow_dispatch`
  is one of the two event types that GITHUB_TOKEN can trigger.
- governance_test.go: TestGovernance_ReleaseAnnouncementWorkflow
  extended to pin the new trigger + dispatch body path; new
  TestGovernance_ReleaseWorkflowDispatchesAnnouncement asserts
  the release workflow contains the dispatch step with the right
  permissions and dependencies.

v1.0.2 was already announced manually; v1.0.3 and onwards will
announce themselves.

Closes #106.
@millerjp millerjp merged commit bac0db2 into main May 17, 2026
25 checks passed
@millerjp millerjp deleted the fix/ci-release-dispatch-announcement branch May 17, 2026 15:07
@github-actions github-actions Bot locked and limited conversation to collaborators May 17, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(ci): release workflow does not trigger downstream release-announcement (GITHUB_TOKEN propagation)

1 participant