Skip to content

Align Three Declared Wait-Loop False Denies With What the Check Reads #2315

Closed

Description

@ptr727

Problem

#2117 narrowed the wait-loop check in host-setup/agent-safety/claude/gh-write-guard.py and declared the false denies it adds in README requirement 7. Its last local strict review pass found three places where the declaration and the code still disagree. None lets an unbounded loop through.

  1. An array assignment used as a command prefix ends the walk back at its ), so this constructed command is denied although bash runs the bound:

    A=(1 2) timeout 900 bash -c 'until [ -f x ]; do sleep 60; done'

    Requirement 7 lists a case pattern, a subshell, an arithmetic compound, and an arithmetic for header as the ) false denies, not an array assignment.

  2. A word with a leading = is read as zsh's path expansion, so timeout 900 env '=x' bash -c '<loop>' is denied, quoted or under bash. No clause declares that false deny.

  3. Requirement 7 says a nesting is bounded only "with no -k given a non-empty value", but the check reads only the last -k, so timeout -s 0 -k 5 -k '' 900 timeout 800 ... is read as bounded. GNU timeout refuses an empty interval with exit 125 before running anything, so this is wording precision only.

Done looks like

Each is either handled in the code with a self-test row, or declared in requirement 7 in words that match what the code reads.

Activity

  1. ptr727 commented on Oct 23, 2026

    @ptr727
    OwnerAuthor

    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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions