claude-code - 💡(How to fix) Fix [BUG] PR review panel shows wrong file diff (same files for all PRs) — diff payload cached/decoupled from branch label

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

In the Claude Code desktop app's PR review panel (right-hand split), the file list + diff content shown does not match the PR currently selected in the pinned-session left pane. All PR rows in the pinned list also display the same LOC counter (e.g. +293/-72), regardless of the actual PR size on GitHub.

The branch label in the right pane (main → feat/<branch>) updates correctly when switching PR rows, but the file tree + diff payload below it appears cached from an earlier-selected PR.

Root Cause

In the Claude Code desktop app's PR review panel (right-hand split), the file list + diff content shown does not match the PR currently selected in the pinned-session left pane. All PR rows in the pinned list also display the same LOC counter (e.g. +293/-72), regardless of the actual PR size on GitHub.

The branch label in the right pane (main → feat/<branch>) updates correctly when switching PR rows, but the file tree + diff payload below it appears cached from an earlier-selected PR.

Fix Action

Workaround

Use gh pr diff <num> or open the PR's Files-changed tab on GitHub for ground truth.

RAW_BUFFERClick to expand / collapse

Summary

In the Claude Code desktop app's PR review panel (right-hand split), the file list + diff content shown does not match the PR currently selected in the pinned-session left pane. All PR rows in the pinned list also display the same LOC counter (e.g. +293/-72), regardless of the actual PR size on GitHub.

The branch label in the right pane (main → feat/<branch>) updates correctly when switching PR rows, but the file tree + diff payload below it appears cached from an earlier-selected PR.

Repro

  1. Pin a session that surfaces multiple draft/open PRs (in my case ~12 PRs from a parallel migration wave, all branched off main).
  2. Click PR row A → right pane loads its diff. Confirm files match.
  3. Click PR row B → branch label in right pane updates to main → <B-branch>, but the file tree + diff content stays as A's payload.
  4. Cycle through every row → all show A's files; LOC counter on every row reads identical placeholder value.

Expected

  • Right-pane file tree + diff content refreshes to match selected PR's branch.
  • Each PR row shows its own additions/deletions count.

Actual

  • Right-pane file tree + diff content stays frozen on first-loaded PR's content.
  • Every PR row in left pane shows identical LOC count.

Verified ground truth by running gh pr view <num> --json additions,deletions,changedFiles and gh pr diff <num> --name-only for each PR — every PR has distinct file lists and distinct LOC totals (ranging from 8 files / +722 add to 40 files / +2531 add in my repro set). Panel was showing one specific older PR's files for every selection.

Likely cause (speculation)

  • Diff payload cached at session level, keyed by something stable across row changes (so subsequent selections reuse the first-loaded payload).
  • OR diff computed against a stale local worktree state — the parent worktree is checked out on different branches at different points, and the panel may be reading from disk rather than from GitHub.
  • The shared LOC value looks like a single placeholder reused for every row.

Environment

  • Claude Code: 2.1.138 (desktop app)
  • OS: macOS 26.4.1 (build 25E253)
  • Repo: private monorepo with many concurrent worktrees under .claude/worktrees/
  • All PRs in repro have base main and distinct heads

Workaround

Use gh pr diff <num> or open the PR's Files-changed tab on GitHub for ground truth.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING