Skip to content

fix(ci): grant reusable callers the permissions their reusable declares - #39

Merged
hyperpolymath merged 1 commit into
mainfrom
fix/caller-permissions
Aug 6, 2026
Merged

fix(ci): grant reusable callers the permissions their reusable declares#39
hyperpolymath merged 1 commit into
mainfrom
fix/caller-permissions

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

The governance and Hypatia workflows here are startup_failure on every run — not failing, never starting.

GitHub refuses to begin a reusable-workflow call whose caller grants less than the reusable itself declares. The refusal happens before any job exists: no log, no check run, no row in gh pr checks.

Why this was misdiagnosed as something else

Because the workflow never emits its status context, a perfectly correct branch rule requiring governance / Validate Hypatia Baseline looks like a phantom — a rule naming something that doesn't exist.

It isn't. The rule is right and the workflow is broken. Rewriting the rule would have converted "this check is broken" into "this check is not required" — which is exactly how enforcement quietly evaporates, and it was the outcome I nearly produced before checking workflow health.

The fix

haec runs the identical reusables at the identical pin, successfully. It grants:

permissions:
  actions: read
  contents: read

The repos stuck at startup_failure grant only contents: read.

This adds the missing actions: read and nothing else. It deliberately does not widen permissions further — over-granting is how a scanner quietly acquires write access it was never meant to have.

Found by the estate CI/CD census (hyperpolymath/standards#583), which pairs what each repository requires against what it actually emits.

🤖 Generated with Claude Code

The governance and Hypatia workflows here are `startup_failure` on every run —
not failing, never starting. GitHub refuses to begin a reusable-workflow call
whose caller grants LESS than the reusable itself declares, and the refusal
happens before any job exists: no log, no check run, and no row in
`gh pr checks`.

That has a second consequence that is easy to misdiagnose. Because the
workflow never emits its status context, a perfectly correct branch rule
requiring `governance / Validate Hypatia Baseline` looks like a PHANTOM — a
rule naming something that does not exist. It is not: the rule is right and
the workflow is broken. Rewriting the rule would have converted "this check is
broken" into "this check is not required", which is how enforcement quietly
evaporates.

The reference is haec, which runs the identical reusables at the identical pin
successfully. It grants:

    permissions:
      actions: read
      contents: read

while the repos stuck at startup_failure grant only `contents: read`.

This adds the missing `actions: read` and nothing else. It deliberately does
not widen permissions further — over-granting is how a scanner quietly gains
write access it was never meant to have.

Found by the estate CI/CD census (hyperpolymath/standards#583), which pairs
what each repository REQUIRES against what it actually EMITS.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Signed-off-by: Jonathan D.A. Jewell <6759885+hyperpolymath@users.noreply.github.com>
@sonarqubecloud

sonarqubecloud Bot commented Aug 6, 2026

Copy link
Copy Markdown

@gitar-bot

gitar-bot Bot commented Aug 6, 2026

Copy link
Copy Markdown

Note

Automatic reviews are paused because your trial's included automatic processing has been used for this period. Upgrade now, or comment "Gitar review" to run a review anytime.
Learn more

Code Review ✅ Approved

Grants actions: read permissions to CI reusable callers to resolve startup failures caused by permission mismatches. No issues found.

Auto-approved and auto-merge armed: No blocking issues found.
Please see Auto-approve Docs for details on setting custom approval criteria. — merges when pipeline and required approvals pass.

Options

Display: compact → Showing less information.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Important

Your trial ends in 4 days — upgrade now to keep code review, CI analysis, auto-apply, custom automations, and more.

Was this helpful? React with 👍 / 👎 | Gitar

@gitar-bot
gitar-bot Bot enabled auto-merge (squash) August 6, 2026 07:42
@gitar-bot gitar-bot Bot added the gitar-approved Added by Gitar label Aug 6, 2026

@gitar-bot gitar-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gitar has auto-approved this PR and enabled auto-merge (configure)

@hyperpolymath
hyperpolymath merged commit 1f8dec0 into main Aug 6, 2026
2 checks passed
@hyperpolymath
hyperpolymath deleted the fix/caller-permissions branch August 6, 2026 09:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gitar-approved Added by Gitar

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant