Checkout Pull Request in Worktree still fetches fork head from base remote in 0.174.0
Maintainer antworten meist innerhalb von 1 Tag
@alexr00 arbeitet bereits daran.
Seit 03.11.2026.
Bewertung
Dieses Issue wurde noch nicht bewertet.
Beschreibung
- Extension version: GitHub Pull Requests 0.174.0
- VS Code version: 1.144.0
- OS: macOS 15.5, Apple Silicon (arm64)
- Repository clone configuration: fork of an upstream repository, with multiple remotes and linked worktrees
- GitHub product: GitHub.com
Related: #8983, which is closed as completed. This report confirms that the same failure remains reproducible with the installed, unmodified 0.174.0 extension. I have not established whether the fix for #8983 was included in this release.
Steps to reproduce
- Clone a fork and configure remotes such as:
origin: your forkupstream: the repository receiving the PRcontributor: the fork containing the PR's head branch
- Open a PR against the upstream repository whose head branch exists only in the contributor's fork.
- In the GitHub Pull Requests view, choose Checkout Pull Request in Worktree and select a new directory.
- Observe that creation fails, even though the head branch can be fetched successfully from the contributor remote.
Actual behavior
The extension attempts to fetch the fork's head branch from the base repository remote.
Sanitized excerpts from the original logs (branch name replaced with a placeholder):
2026-11-02 17:50:53.859 [info] > git fetch upstream <fork-only-branch> [1896ms]
2026-11-02 17:50:53.859 [info] fatal: couldn't find remote ref <fork-only-branch>
2026-11-02 17:50:54.495 [error] [Worktree] Failed to create worktree: Failed to execute git
The UI only shows the generic Failed to execute git error, so the incorrect remote is visible only in the Git output.
The failed attempt above was made after removing an earlier local workaround and updating VS Code and the extension. The bundled checkoutPRInWorktree implementation in the unmodified 0.174.0 extension still obtains the remote from pullRequestModel.remote.remoteName and fetches prHead.ref from that remote.
Expected behavior
Resolve the remote corresponding to the PR's head repository and fetch the head branch from it, reusing or creating the contributor remote as needed. Use that same remote when selecting the worktree's starting remote-tracking branch.
Workaround / possible fix
Reusing the existing PullRequestGitHelper.createRemote(repository, pullRequestModel.remote, prHead.repositoryCloneUrl) helper before the fetch fixes remote selection locally. Use the returned remote name both for the fetch and for the remote-tracking branch passed to worktree creation.
With this approach, the original UI command was verified to fetch from the contributor remote and successfully create and open a worktree on 0.144.0. I have restored an equivalent local workaround for 0.174.0; the logged failure above is from the unmodified release, not the patched version.
A regression test with a head branch present only on a fork, plus a base remote named upstream, would help cover this topology.
- Vorherrschende Sprache
- TypeScript
- Sterne
- 2.6k
- Forks
- 811
- Ø Merge
- 1 T. 8 Std.
- Gemergte PRs (30 T.)
- 70
Entwicklungsumgebung
Dieses Projekt bietet weder Dev-Container noch Dockerfile noch Beitragsleitfaden – die Einrichtung liegt bei Ihnen. Beginnen Sie mit der README; die allgemeinen Schritte stehen in unserem Leitfaden für den ersten Beitrag.
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus microsoft/vscode-pull-request-github
-
Cannot open PR: null review comment commit causes TypeError (reading 'oid')Evtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
microsoft/vscode-pull-request-github#9159 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Merging from the PR description tab shows "Error refreshing pull request description: Webview is disposed"Evtl. vergeben @alexr00 hat das vor 3 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
microsoft/vscode-pull-request-github#9143 · 1 Reaktion · 2 zugewiesene Personen ·
Maintainer antworten meist innerhalb von 1 Tag
-
Honor open-to-side placement when opening GitHub PR and issue linksEvtl. vergeben @alexr00 hat das vor 3 Tagen übernommen. Offenfeature-request
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
microsoft/vscode-pull-request-github#9072 · 1 Reaktion · 2 zugewiesene Personen ·
Maintainer antworten meist innerhalb von 1 Tag
-
[github.dev] 0.176.0: Pull Requests view missing and PR info fails to open (0.174.0 works)Evtl. vergeben @alexr00 hat das heute übernommen. Offenbug candidate
microsoft/vscode-pull-request-github#9162 · 2 Kommentare · 5 Reaktionen · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 48/100
microsoft/vscode-pull-request-github#9161 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in microsoft/vscode-pull-request-github
Ähnliche Issues
-
unwrapDatabaseError masks real DB errors with TypeError: Cannot convert object to primitive valueOffen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
NEARBuilders/everything-dev#798 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
vercel-labs/durable-harness#53 ·
Maintainer antworten meist innerhalb von 1 Tag
-
[Bug]: Redesign tab bars ignore clicks on Linux: hidden chat layers keep window drag regionsEvtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
Maintainer antworten meist innerhalb von 1 Tag
-
experiência: a doc manda subir para o Micro do Supabase, mas não diz que exige plano pago nem quanto custaEvtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offenarea/docs area/ui enhancement
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 88/100
melgarafael/DeskcommCRM#4098 ·
Maintainer antworten meist innerhalb von 1 Tag
-
dependencies platform: ios
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 78/100
software-mansion/react-native-executorch#1617 ·
Maintainer antworten meist innerhalb von 1 Tag