Skip to content

ci: release gate action and workflow template, the candidate read as data and the check posted by an app - #55

Merged
pwngh merged 1 commit into
mainfrom
m4-workflow
Dec 2, 2026
Merged

pwngh merged 1 commit into
mainfrom
m4-workflow

Conversation

@pwngh

@pwngh pwngh commented Dec 2, 2026

Copy link
Copy Markdown
Owner

The release gate runs on pull requests, including ones from forks, while holding the model key and the app's key. It must never run the pull request's code, and only a dedicated app may post the check a branch rule trusts.

actions/release-gate/ holds a composite action and the workflow template users copy (kept out of .github/workflows, so it never runs here). The workflow triggers on pull_request_target into the default branch only, with no GITHUB_TOKEN permissions, in a protected environment; its one checkout is the default branch, without credentials. The action mints the app's installation token (checks write, contents read, pull requests read), reads flow/candidate.toml and the one system prompt it names at the head commit through the contents API, as data (flowd/check/github.py, standard library only), runs flow check from the action's own copy of Flow with isolated Python, and posts flow/release-gate on the head commit: success only for passed. Every action is pinned to a commit.

Proof: tests/check/test_github.py (10 tests against a fake GitHub API: the candidate read only at the head commit and a script beside it never run; bad candidates refused; no repository path echoed into logs; the check posted with the app's token on the head commit with the exact name, success only for passed; static checks that the workflow never checks out the pull request and every Python call is isolated). Both YAML files parse; anthropic==2.16.0 installs on a clean Python 3.12. Full Python suite passed.

Reviewed with sol-loop: 3 rounds with gpt-6.2-sol. Sol verdict: approved

@pwngh
pwngh force-pushed the m4-workflow branch 4 times, most recently from 7360298 to 378eb80 Compare December 2, 2026 09:15
@pwngh
pwngh merged commit 65344bc into main Dec 2, 2026
24 of 26 checks passed
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