Skip to content

Detect if the user has multiple accounts, and if the one configured for the workspace might be the wrong one #7745

Open

Description

@acv-bhai

I'm using this extension with VSCode Insider and I keep receiving this notification.

Image

What I think might be causing this issue is because I have two git accounts configured in my macos using Git Credential Manager. One for personal use and one for work use. And because of that my remote origin URL will be having [email protected] in my work related repos. is that a reason?

I have this extension working in VSCode for my personal repos for which remote url doesn't contain username.

I'm using VS Code for personal repos and VSCode insider for work repos.

Here is my VSCode Insider Details:

Version: 1.104.0-insider (Universal)
Commit: 966ec1415440da5f1ef53acbd97ba2113add8853
Date: 2025-09-02T05:05:45.743Z
Electron: 37.3.1
ElectronBuildId: 12259562
Chromium: 138.0.7204.235
Node.js: 22.18.0
V8: 13.8.258.31-electron.0
OS: Darwin arm64 24.6.0

Activity

  1. acv-bhai commented on Sep 4, 2025

    @acv-bhai
    Author

    hey folks is there something that I'm missing or any additional information is required?

  2. alexr00 commented on Sep 12, 2025

    @alexr00
    Member

    A few questions/thoughts:

    • Are you signed in to VS Code with GitHub with multiple accounts? If so, you can choose which one is used with this extension.
    Image Image
    • What is the output of git remote -v? If you have remotes that you want the extension to ignore, you can remove them from githubPullRequests.remotes.
  3. acv-bhai commented on Sep 12, 2025

    @acv-bhai
    Author

    Alex Ross (@alexr00) many thanks for your time and response. Yes I have multiple accounts logged in. Your screenshot helped me to figure out the mistake and now its sorted. Thanks again for your support.

  4. alexr00 commented on Sep 16, 2025

    @alexr00
    Member

    TylerLeonhardt FYI. I've seen a couple times that folks are having a hard time finding this.

  5. TylerLeonhardt commented on Sep 19, 2025

    @TylerLeonhardt
    Member

    This functionality is also in a few other places:

    • right click on an extension in the the extension list -> Account Preferences
    • (new in 1.104) a command in the Command Palette for Managing Account Preferences

    ... besides adding yet another item to the Account menu, I'm not sure where else to put this tbh

  6. alexr00 commented on Sep 23, 2025

    @alexr00
    Member

    TylerLeonhardt and I discussed this. If we can detect in the PR extension that you might be using the wrong account, then we should show a modal dialog and then run the "Manage account preferences" command.

  7. added
    feature-requestRequest for new features or functionality
    and removed
    info-neededIssue requires more information from poster
    on Sep 23, 2025
  8. changed the title [-]Fetching pull request from remote origin with query failed, please check if the repo undefined is valid[/-] [+]Detect if the user has multiple accounts, and if the one configured for the workspace might be the wrong one[/+] on Sep 23, 2025
  9. chefranov commented on Sep 23, 2025

    @chefranov

    I have similar issue #7835
    Bhai (@acv-bhai) what was your mistake?

  10. Hydhen commented on Sep 24, 2025

    @Hydhen

    I have the same problem, even with a single logged in account

  11. TylerLeonhardt commented on Sep 24, 2025

    @TylerLeonhardt
    Member

    Loïc Juillet (@Hydhen) then you must be hitting something else. Open a new issue.

  12. modified the milestones: November 2025, on Dec 1, 2025
  13. removed this from the milestone on Jan 5, 2026
  14. JohnGalt1717 commented on Apr 15, 2026

    @JohnGalt1717

    This plugin entirely fails to load anything if you set it to a different github account in vs code from the user menu than the default account for the entire window.

    Making it useless if you have multiple credentials you need to manage per workspace.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

feature-requestRequest for new features or functionality

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions