I'm getting HTTPS: 403 error while pushing to the repo:
Enumerating objects: 1007, done.
Delta compression using up to 8 threads
Compressing objects: 100% (264/264), done.
Writing objects: 100% (376/376), 139.79 KiB | 3.58 MiB/s, done.
Total 376 (delta 278), reused 151 (delta 101), pack-reused 0
error: RPC failed; HTTP 403 curl 22 The requested URL returned error: 403
send-pack: unexpected disconnect while reading sideband packet
fatal: the remote end hung up unexpectedly
Everything up-to-date
Git version:
$ git --version
git version 2.40.0
First, I was a collaborator to the project and this worked well about a month ago, but 1-2 weeks ago it stopped working, nobody touched the repo! Then I transferred this repo from user A to myself, I thought that permissions are broken, but I still can push to repositories created by myself with same tokens. So, credentials are correct 100%.
Also, an opened PR is associated with this repo, but I can neither push to the PR's branch nor create a new one, even though I'm an owner. What can cause this behavior and how to make it work?
P.S.: I didn't try to use ssh instead, this is, actually, not possible for me now, so I use https.
HTTP status 403 is "Unauthorized" - you've provided valid credentials and authenticated successfully, but the account you're using is not permitted to perform the action you've requested.
Unfortunately, there isn't enough information here to provide a concise diagnosis, but a few broad possibilities come to mind:
git remote -v; if the remote URL is incorrect, then you can fix it with git remote set-url $REMOTE_NAME $NEW_URL.for me, the following process worked
https://github.com/rohit/xyz
to
https://github.com/rohit/xyz.git
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With