fix(notify): keep recovery gate read-only#118
Conversation
Grant the owner publication gate only the Actions read permission needed to validate the bound failed run. Allow the read-only gate to defer an invisible draft to the existing write-isolated staging resolver, which refuses to recreate a missing recovery draft before any release mutation.
|
Important Review skippedNo new commits to review since the last review. ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
📝 WalkthroughWalkthroughThe publish-gate workflow now uses explicit read-only permissions. Recovery mode accepts an unavailable draft release and reports that draft visibility is deferred to later recovery staging logic. The safety script validates both requirements. ChangesPublish gate safety
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 7✅ Passed checks (7 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
Summary
actions: readin addition to its existingcontents: read, so it can validate the exact failed workflow run and jobs;contents: writestaging resolver, which requires exactly one matching release and refuses to recreate a missing draft during recovery before any release mutation.Failure evidence
Recovery run
29332225420completed its notify guard and publication safety policy, then failed closed inOwner Publish Gate. Every registry, image-selection, binary, draft-staging, rollout, finalization, and public-verification job was skipped, so the failed recovery attempt changed no release state.The exact tag, source commit, failed source run, draft, rollback release, image digest, platform digests, attached image attestations, and five binary attestations were independently reverified before this change. GitHub's release API exposes drafts only to callers with push access, while this gate intentionally remains read-only.
Security and compatibility
packages: read;Verification
ruby -c .github/scripts/notify-publish-safety.rbruby .github/scripts/notify-publish-safety.rbactionlint1.7.12 with ShellCheck 0.10.0zizmor --offline1.26.1: no findingscd notify && GOTOOLCHAIN=local go test ./... -count=1git diff --checkRelease truth
Helper publication remains incomplete until a new exact-main recovery run passes immutable image and binary verification, draft staging, published upgrade/rollback/forward-recovery proof, finalization, and public read-only verification.