docs: enforce_admins is now TRUE — the push guard's notes said the opposite - #32
Merged
Conversation
…posite `enforce_admins` was enabled on MEFORORG/MessageFoundry main on 2026-07-28 (verified from the protection endpoint, not the write response). A direct push to `main` is now refused SERVER-SIDE and `gh pr merge --admin` no longer works. push_guard.py's header and its refusal message both stated the opposite -- "enforce_admins is false, so the owner bypasses it. Nothing else would have stopped this." That was accurate when written and is now exactly backwards, and it is the kind of claim someone reads while deciding whether the hook still matters. WHY THE HOOK STAYS. It is defence-in-depth now rather than the only guard, and it still earns its place: it fails FAST and LOCALLY with an explanation instead of after a round-trip, and it covers `cla-signatures`, which branch protection does not. The header also records why the reasoning INVERTED, because that is the reusable part. It used to argue `enforce_admins=true` was deliberately deferred: an intermittent harness-monitor failure was blocking consecutive PRs, and removing the admin override while a flake can strand a merge trades an accidental-push risk for a cannot-ship risk. That failure was a LIVELOCK, not a flake -- so the premise dissolved rather than the trade-off being re-argued. The cannot-ship risk is real and now accepted, with the revert command in the note. COMMENTS ONLY -- no logic touched. Verified: 8 tests pass, and the guard still exits 1 on a push to `main` and 0 on a feature branch. (Read those exit codes WITHOUT a pipe: my first check piped stdout to Select-String and reported exit 0 for a push it had just REFUSED -- the same "exit code read through a pipe belongs to the pipe" trap already recorded for the leak scanner.)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
enforce_adminswas enabled onMEFORORG/MessageFoundrymainon 2026-07-28 (verified from the protection endpoint, not the write response). A direct push tomainis now refused server-side, andgh pr merge --adminno longer works.push_guard.py's header and its refusal message both stated the opposite:Accurate when written, exactly backwards now — and it's the claim someone reads while deciding whether the hook still matters.
Why the hook stays
It's defence-in-depth rather than the only guard, and it still earns its place: it fails fast and locally with an explanation instead of after a round-trip, and it covers
cla-signatures, which branch protection does not.The header records why the reasoning inverted
That's the reusable part. It used to argue
enforce_admins=truewas deliberately deferred: an intermittent harness-monitor failure was blocking consecutive PRs, and removing the admin override while a flake can strand a merge trades an accidental-push risk for a cannot-ship risk.That failure turned out to be a livelock, not a flake — so the premise dissolved rather than the trade-off being re-argued. The cannot-ship risk is real and now accepted, with the revert command recorded in the note.
Verification
Comments only — no logic touched. 8 tests pass, and the guard still exits
1on a push tomainand0on a feature branch.Worth noting how I checked that: my first attempt piped stdout to
Select-Stringand reported exit 0 for a push it had just REFUSED — the same "an exit code read through a pipe belongs to the pipe" trap already recorded for the leak scanner. Re-measured without the pipe.🤖 Generated with Claude Code