Pull requests in Android Studio: Can't load data from GitHub. [Could not resolve to a Repository with the name xxx]

Issue

I am having this issue in Android Studio while trying to open Pull requests in the IDE. I have two accounts logged in for github in my Android studio (personal and work)

Can’t load data from GitHub. [Could not resolve to a Repository with the name xxx]

I looked up online for some solutions and so far I’ve tried –

  1. Removing my account and adding it again using token.
  2. IDE invalidate cache and restart

None of the solutions worked for me.

Solution

I tried solving this for an hour and found nothing online but eventually it worked so sharing what worked for me here:

I found this dialog that opens when:

(Pull request -> Settings icon at top right -> click on Change Repository or Account

and then I clicked on the account I needed to access that specific repository. In my case, the issue was I had two accounts logged in (Personal and work) and even though it’s strange because I remember opening pull requests a week back and then it was working. But today it gave an error. But anyway, this fixed it. Hope this helps 🙂

Answered By – Pooja Singh

This Answer collected from stackoverflow, is licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0

Leave a Reply

(*) Required, Your email will not be published