Skip to content

docs + enqueue-guard: four follow-ups from the #1348 review (non-blocking) #1350

Closed

Description

@Birfy

Four non-blocking findings from the review of #1348@de4cca5a (PASSed, enqueued as #1348). They must not be folded into #1348: editing that tip voids the verdict on it, so they land as their own change.

  1. AGENTS.md → Untrusted external agent branches: add the "a renamed branch walks past it" sentence. Reviewer wording: a renamed branch, or a body whose marker was never there, walks past it.
  2. AGENTS.md:203 (One conclusion per tip) still states the old account rule — it talks about type: Bot / [bot] logins and does not say that a report without any type is refused too. The same file therefore carries two versions of rule 7. Align that paragraph with the shipped accountRefusal(): only type === 'User' counts, a missing type is refused, and a bot's account name lives in judged, not in reasons.
  3. enqueue-guard.mjs frozenRefusal(): the "this PR edits the list itself" branch runs before if (pull?.merged) return null, the opposite of what its own comment says. A merged PR re-run by a later labeled event is therefore judged red. Put the merged short-circuit first and add a case that proves a merged PR is not refused.
  4. The new section's "this rule lapses from the day the cursor cloud agent's write access is revoked" does not match how the gate actually releases — the gate reads .github/agent/frozen-branches.json from the base commit, so the release is deleting that file (or its entries) on main. Bind the sentence to that deletion instead of to an event nobody can observe in the repo.

Scope

  • .github/scripts/enqueue-guard.mjs — only the frozenRefusal() ordering (item 3)
  • .github/scripts/enqueue-guard.test.mjs — one case for item 3, fixtures only otherwise
  • AGENTS.md — items 1, 2 and 4

Not allowed: core/, patches/, .github/workflows/pass-label.yml, package*.

Evidence expected

Same six columns as any PR: Reproduce (a re-run of enqueue-guard on a merged pull object returns a refusal today), What changed, What I ran, Red without the source change (revert the ordering fix → the new case is the one that goes red), Not run, Risk.

Owner

Dev.

Constraint

Do not touch #1348's branch or tip. One PR for this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:automationScheduled tasks and automationbugSomething isn't workingdocumentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions