Skip to content

Review Pass reviews Spec-run Ticket PRs: closing issues aren't linked for non-default bases #2290

Closed

Description

@JacobStephens2

This was generated by AI during triage.

Agent Brief

Category: bug
Summary: An author Review Pass reviews a Spec run's Ticket pull requests, because its admission check finds their closing issue only through GitHub's closingIssuesReferences, which is empty for pull requests into a non-default base.

Current behavior:

src/processes/review/admission.rs (eligible) skips a pull request when one of github.closing_issues(pr) carries in-progress or a held issue reservation. A Ticket PR in a Spec run targets the Spec's branch (issue-<spec>), not the default branch, and GitHub links closing issues only for pull requests into the default branch. So the list is empty, nothing is held, and an author Pass on another host reviews the Ticket PR while the Spec run is delivering it.

Evidence, 2026-11-18, thirdshift 0.37.0:

Desired behavior:

An author Review Pass skips a pull request that another live Command is delivering, even when GitHub doesn't link its closing issue:

  • For a pull request whose base branch is a thirdshift Issue branch (issue-<n>), also check issue #n for an in-progress Claim or a held reservation, and skip with a reason naming the Spec.
  • When closingIssuesReferences is empty, read closing keywords (Closes/Fixes/Resolves #n) from the pull request body and apply the same holds to those issues.
  • The skip line has the same form as today's closing-issue holds.

Key interfaces:

  • admission::eligible in src/processes/review/admission.rs.
  • GitHub::closing_issues and the pull request snapshot (base and head branch, body).
  • How Issue branch names are made (issue-<n>), so the base-branch check uses the same rule rather than a regex copy.

Acceptance criteria:

  • A fake-gh test: a PR into issue-<n> whose issue #n is in-progress is skipped by an author Pass, and the skip names #n.
  • A PR with empty closingIssuesReferences whose body says "Closes #m", with #m reserved, is skipped.
  • A PR into the default branch with no hold is still reviewed (no regression).
  • Docs updated where the guide describes which pull requests a Review Pass skips.

Out of scope:

Activity

  1. added
    bug
    ready-for-agent
    in-progress
    and removed
    ready-for-agent
    on Nov 19, 2026
  2. JacobStephens2 commented on Nov 19, 2026

    @JacobStephens2
    OwnerAuthor

    This was generated by AI during triage.

    This bug broke a Spec run an hour after it was filed. At 19:01 EST, lima-thirdshift's author Review Pass took Ticket PR #2287 (base issue-2023, head issue-2282), which factory's Spec run for #2023 was delivering. At 20:07 the Review pushed two fix commits to issue-2282 (c7d544d0, 6862ea40). factory's Spec run had made its own fix for the same Security-review finding, and at 20:08 its push of issue-2282 was rejected as non-fast-forward. So #2282 failed, #2284 and #2285 were blocked behind it, and #2023 ended failed with agent-failed.

    So the race costs more than wasted review time: an author Pass can make a Spec run fail. Lima's thirdshift Review cron is paused until this ships.

  3. removed
    in-progress
    on Nov 19, 2026
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

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions