You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Read Only Real GH_REPO Setters as Unread in the Write Guard #3286
Raised by Copilot on #3283, against _gh_repo_unread_export in host-setup/agent-safety/claude/gh-write-guard.py. It was raised after that pull request's second fix round, so it is filed here under the drive's stop rule.
A False Deny
_gh_repo_unread_export fails closed when a _GH_REPO_SETTERS word names GH_REPO among its operands. It does not check whether the builtin and its options actually set the variable. So a command that only reads it, or names it as text, makes a later gh write that takes GH_REPO fail closed. These are constructed examples, origin example/repo:
declare -p GH_REPO; gh pr comment 5 -b x prints the variable.
printf GH_REPO; gh pr comment 5 -b x uses it as a format string, with no -v.
builtin echo GH_REPO; gh pr comment 5 -b x echoes it.
Each is denied as a write taking its repository from a GH_REPO a builtin may set, where each should be allowed. The denial is deny-ward, so it opens no cross-owner write.
Possible Direction
Require -v for printf, read the builtin builtin delegates to, and leave a query-only declare -p or typeset -p alone. Keep failing closed on any form the reader cannot place, and check the change with a develop-versus-branch differential that shows no allow-flip on a cross-owner write.
Closed under the maintainer's decision (ptr727, 2026-10-23) on #3391: the backlog keeps real bugs with a stated failure, features the maintainer wants, and open decisions. A finding the review loop filed on code or text a change did not touch, a refactor or consolidation chore, a tracker, a wording item, or a guard shape no session has produced is closed rather than worked. Reopen with the input and the wrong result if this issue states one.
Activity
Read Owner Flags, Issue Links, and Run-Time Paths in the Write Guard (#…
ptr727 commentedon Oct 23, 2026
Closed under the maintainer's decision (ptr727, 2026-10-23) on #3391: the backlog keeps real bugs with a stated failure, features the maintainer wants, and open decisions. A finding the review loop filed on code or text a change did not touch, a refactor or consolidation chore, a tracker, a wording item, or a guard shape no session has produced is closed rather than worked. Reopen with the input and the wrong result if this issue states one.