11

We are unable to access this connected repository on GitHub The authorization key is not valid, or the account used to connect to GitHub doesn't have access to the repository. Try disconnecting the repository above and then reconnect. That is the error I got when trying to connect my private GitHub repo to Heroku.

I've tried doing everything like making it public, or making a new repository, but it just won't work.

I don't have any code to show, since this is a Heroku problem, not a problem with the code.

I don't know what to do.

Ghonima
  • 2,978
  • 2
  • 14
  • 23
EndoYT
  • 113
  • 1
  • 1
  • 4

2 Answers2

26

As on date 15 April 2022, there is security issue reported on github.

In action of the same, Heroku will not be reconnecting to GitHub till uncertain duration.

Action over the incident is reported on Heroku.

Courtesy: stackoverflow and salesforce stack-exchange

Bhavik Parmar
  • 424
  • 1
  • 6
  • 9
12

I have just had and fixed this issue hopefully I can help. Are you setting up a new repository by any chance? What worked for me was to actually add some files the to the repository and push to GitHub, then Heroku was able to read from the repo then. Hope this helps.

ryantk
  • 136
  • 1
  • 2
  • 1
    This really helped, thanks! Turns out you cannot connect an empty repository, so I just added my files first and then it worked. – EndoYT Dec 04 '19 at 18:51
  • This worked for me too. You cannot currently connect Heroku to GitHub if you've only just created an empty repository. – Olney1 Jul 26 '22 at 09:07