Skip to content

fix(ci): manual workflow_dispatch fallback for release.yml#42

Merged
hiskudin merged 2 commits into
mainfrom
fix/release-please-trigger-pat
May 19, 2026
Merged

fix(ci): manual workflow_dispatch fallback for release.yml#42
hiskudin merged 2 commits into
mainfrom
fix/release-please-trigger-pat

Conversation

@hiskudin

@hiskudin hiskudin commented May 19, 2026

Copy link
Copy Markdown
Collaborator

Summary

v1.7.0 landed in Releases with zero assets because the tag push made by release-please-action (default `GITHUB_TOKEN`) doesn't fire downstream tag-keyed workflows. That's GitHub's deliberate anti-loop guard.

A PAT-based fix was tried in the first commit but needs StackOneHQ org-level approval to issue, which would block this. The second commit replaces it with a manual `workflow_dispatch` fallback — no secret needed, no org approval needed.

How it works

After release-please opens + merges a Release PR, the next tag (eg `v1.7.1`) will exist but may have no assets. To populate:

  1. Go to Actions → Build and Release → "Run workflow".
  2. Type the tag name (eg `v1.7.1`).
  3. The workflow checks out that tag's commit, builds + signs + notarizes both arch artifacts, and attaches them to the matching release.

The auto path (push of a user-pushed tag → workflow fires) still works for any future tags pushed by an account rather than the actions bot. The branch factors the tag handling through a `TARGET_TAG` env so both trigger sources go through the same logic.

Backfilling v1.7.0

Once this lands on main, dispatch the workflow against `v1.7.0` once and the existing release will get its two `.tar.gz` artifacts.

Future: full automation

If/when the StackOneHQ org approves a fine-grained PAT, we can plumb it through release-please-action and remove the manual dispatch step. The dispatch path is harmless to keep around as an escape hatch.

Test plan

  • Merge this PR (will be a v1.7.1 patch bump via release-please)
  • Dispatch `Build and Release` against `v1.7.0` to backfill assets
  • When the release-please PR for v1.7.1 lands, dispatch again against `v1.7.1` and confirm assets attach

🤖 Generated with Claude Code

hiskudin and others added 2 commits May 19, 2026 17:31
The default GITHUB_TOKEN deliberately suppresses downstream workflow
triggers — so when release-please-action created the v1.7.0 tag after
PR #41 merged, the `Build and Release` workflow (push: tags: v*)
never observed it. The release sat empty.

Pass a fine-grained PAT (RELEASE_PAT) with Contents: read/write so the
tag push looks like a normal user push, which DOES fire downstream
workflows.

Add RELEASE_PAT as a repo secret before this lands. For v1.7.0 itself,
manually re-push the existing tag once to backfill its assets:

  git fetch --tags
  git push origin :refs/tags/v1.7.0
  git tag -d v1.7.0
  git tag v1.7.0 origin/main
  git push origin v1.7.0

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The PAT approach in the previous commit needs org-level approval on
StackOneHQ to issue a fine-grained token, which is delaying things.

Instead, add a manual `workflow_dispatch` entry point to release.yml so
any release-please-created tag (whose original push doesn't fire
downstream workflows due to GitHub's anti-loop guard on GITHUB_TOKEN)
can be picked up via Actions → "Run workflow" → enter tag name.

Factored via TARGET_TAG env var so the auto path (push: tags: v*) keeps
working unchanged for tags pushed by a user account.

Revert the release-please.yml PAT change — back to the default
GITHUB_TOKEN, with a comment explaining the manual fallback.

For v1.7.0 itself: once this lands, dispatch against v1.7.0 from Actions
and the existing release page gets its artifacts.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@hiskudin hiskudin changed the title fix(ci): use PAT in release-please so tag push triggers release.yml fix(ci): manual workflow_dispatch fallback for release.yml May 19, 2026
@hiskudin hiskudin merged commit c978b63 into main May 19, 2026
4 checks passed
@hiskudin hiskudin deleted the fix/release-please-trigger-pat branch May 19, 2026 16:54
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