Files
orca/src/main/github/client/lookup
Kelvin Amoabaandagustin2606 47506f3f33 fix(github): link a branch's open PR instead of a newer closed one (#37452)
* fix(github): prefer the open PR when a branch has several

The branch lookup asked GitHub for one PR across all states. GitHub sorts
a branch's PRs newest first, so a closed PR opened after the live one
shadowed it and got linked to the worktree on every checkout.

Fetch a page of the branch's PRs, REST and the `gh pr list` fallback alike,
and take the open one; with none open, keep the newest as before.

* refactor(github): keep branch lookup casts on their own lines

---------

Co-authored-by: agustin2606 <agustinvarela2606@gmail.com>
2026-11-02 10:59:44 +00:00
..