Skip to content

Drop the permission preflight from the GitHub outdated-thread sweep #2209

Done

Description

@ifireball

Parent

#478

Related issue

#2196 covers attempting mutations for finding dispositions. This issue is specifically for the separate GitHub-outdated-thread sweep.

What to build

Remove viewerCanResolve as a selection gate in the GitHub outdated review-thread sweep. The sweep currently filters for viewerCanResolve == true before issuing resolveReviewThread; when a bot token reports false, it skips the mutation entirely. This sweep is separate from the finding-specific stale-thread reconciliation added in #2204, which already lets the resolve mutation's response decide.

Keep the existing safety conditions for open, outdated threads whose complete comment list contains only outdated comments authored by the review bot. Attempt resolution for each eligible thread and handle the mutation result. If it fails, leave the thread open, continue the run, and report the thread link and next step.

Acceptance criteria

  • viewerCanResolve does not gate selection or resolution of otherwise eligible outdated GitHub review threads.
  • A false bot-token permission lookup still leads to an attempted resolve mutation for an eligible thread.
  • A successful mutation resolves the thread; a failed mutation leaves it open and is reported with a direct link and practical next step.
  • The cleanup remains best-effort and does not fail the review run.
  • Tests cover viewerCanResolve=false with successful and failed mutation responses, while preserving the outdated-comment and bot-author safety checks.

Activity

  1. added
    bug
    on Nov 30, 2026
  2. self-assigned this
    on Nov 30, 2026
  3. fullsend-ai-triage commented on Nov 30, 2026

    @fullsend-ai-triage

    🤖 Finished Triage · ✅ Success · Started 11:25 AM UTC · Completed 11:27 AM UTC

    Commit: ef1bb84 · View workflow run →

    Runtime: claude · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $0.14

  4. added
    ready-to-code
    on Nov 30, 2026
  5. fullsend-ai-triage commented on Nov 30, 2026

    @fullsend-ai-triage

    This looks ready to implement. A few notes beyond the issue text:

    • The gate appears in more than one place: the shell selector in scripts/lib/github-review-ops.lib.sh (bundled into scripts/post-review.sh and scripts/pre-review.sh) and the thread filter in scripts/process-fix-result.py. All of them should be covered, and the bundles need regenerating with make script-build / make check-bundle.
    • Keep the safety checks intact: unresolved, outdated, complete comment pagination, at least one comment, all comments outdated, all authored by the review bot.
    • On a failed mutation the thread should stay open and be reported with a link and next step, without failing the run.
    • No open PR currently addresses this, and no workflow files need to change.

    Proposed test cases:

    1. Eligible outdated bot-only thread, viewerCanResolve=false, mutation succeeds -> thread resolved.
    2. Same thread, mutation fails -> thread left open, link + next step reported, run exits successfully.
    3. Safety checks still skip: not outdated, already resolved, any non-outdated comment, any non-bot comment, incomplete comment pagination, empty comment list.
    

    Next steps:

    • /fs-code — agent creates a PR to implement this issue
    • /fs-code <your instruction> — agent implements with your specific guidance
  6. fullsend-ai-coder commented on Nov 30, 2026

    @fullsend-ai-coder
    Contributor

    🤖 Finished Code · ✅ Success · Started 11:29 AM UTC · Completed 12:02 PM UTC

    Commit: ef1bb84 · View workflow run →

    Runtime: claude · Model: opus → claude-opus-5-5 · Effort: high · Cost: $2.80

  7. added 3 commits that reference this issue on Nov 30, 2026
  8. added a commit that references this issue on Nov 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugready-to-codereview-agent

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions