Desktop Code tab: PR chip retains 'Merged' badge and stale link after branch switch
Surface
Claude Desktop app, Code tab (not the terminal/TUI). The PR chip rendered above the prompt input.
Description
The PR status chip in the Code tab updates the branch name when switching to a new branch with an open PR, but does not refresh the merge badge or the underlying link. The chip continues to render \"Merged\" and the link points to the previously-merged PR, even though the displayed branch is now a different branch with an open PR.
Reproduction
- Open a PR from branch A (e.g. \
refactor/icon-catalog\). - Have it merged (lead/reviewer merges it).
- In the same desktop session, create a new branch B from \
main\(e.g. \feat/glass-button-small-variant\) and open a new PR for it via \gh pr create\. - Look at the PR chip above the prompt in the Code tab.
Expected: chip shows branch B name, an \"Open\" status (or no badge), and clicking it navigates to the new PR.
Actual: chip shows branch B name and a \+41 -11\ diff stat (correctly reflecting branch B), but the badge still reads \"Merged\" and clicking the chip navigates to the old, merged PR for branch A.
Screenshot
<img width="815" height="120" alt="Image" src="https://github.com/user-attachments/assets/e2a0b435-1ba3-4d35-8f6c-60ad7201eadf" />
Verification that the new PR is genuinely open
\\\\
$ gh pr view 194 --json state,mergedAt
{\"mergedAt\":null,\"state\":\"OPEN\"}
\\
So the data source (GitHub) reports \"OPEN\", but the desktop chip still surfaces the previous merged state.
Environment
- Surface: Claude Desktop, Code tab
- Host OS: macOS (Darwin 25.3.0)
- Workflow: opened a fresh branch from \
origin/main\after a previous PR on a different branch had been merged within the same session
Workaround
Refreshing the PR panel or restarting the desktop client clears the stale state.
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗