Skip to content

Read a Thread's Outdated Flag Rather Than a Null Line in pr_review_copilot.py's listed_lines #3701

Closed

Description

@ptr727

Summary

listed_lines in scripts/pr_review_copilot.py reads a thread whose first comment has a null line as outdated. GitHub also returns a null line and startLine for a current file-level thread, one whose subjectType is FILE. Such a thread marks every findings-list item citing its file [outdated thread on its path], and that item drops out of the unmatched count.

Reproduction

A constructed case: a pull request changing src/a.py. The head round's body holds 1 open issue with one linked entry, and an Outstanding findings: list with one item citing `src/a.py:12`. The one open thread is a current file-level comment on src/a.py, so its first comment carries line: null.

pr_review.py status prints that item as [outdated thread on its path]. The open count and the linked entry balance, so unthreaded is 0 and the unmatched count is 0. No FINDINGS WITH NO THREAD block prints, and the finding is dropped silently.

The README sentence "An outdated thread on that path is named rather than counted, since its lines predate the head" is wrong for this case too.

Fix

Read isOutdated on the thread, or outdated on the comment, in Q_FULL in scripts/pr_review.py. Treat a thread as outdated on that field rather than on line is None. A current file-level thread then marks no item, and the item counts as unmatched.

Found by the strict-review pass on the pull request for #3672 and #3489, after its edit budget was spent.

🤖 Generated with Claude Code

Activity

  1. ptr727 commented on Oct 31, 2026

    @ptr727
    OwnerAuthor

    Claim: feature/burndown-3672-3489 (PR #3702) fixes this inside its existing claim (scripts/pr_review.py, scripts/pr_review_copilot.py, scripts/README.md, tests/test_pr_review_copilot.py), after Copilot raised the same defect on #3702. It joins that PR's Closes on promotion: line.

  2. ptr727 commented on Oct 31, 2026

    @ptr727
    OwnerAuthor

    Claim released: feature/burndown-3672-3489 merged to develop as #3702 and its branch and worktree are cleaned up. This issue closes when the next develop -> main promotion merges.

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions