'GERRIT: ! [remote rejected] HEAD -> refs/for/master (internal server error)
It was working fine. Now, when I try to push
git push origin HEAD:refs/for/master
I get,
Counting objects: 5, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 310 bytes, done.
Total 3 (delta 1), reused 0 (delta 0)
remote: Resolving deltas: 100% (1/1)
remote: Processing changes: refs: 2, done
To ssh://[email protected]:29412/gerrit_prj_1
**! [remote rejected] HEAD -> refs/for/master (internal server error)**
error: failed to push some refs to 'ssh://[email protected]:29412/gerrit_prj_1'
In the gerrit_server error log, i see,
[2014-01-16 15:57:03,722] ERROR com.google.gerrit.server.git.ReceiveCommits : Only 0 of 1 new change refs created in gerrit_prj_1; aborting
I am using gerrit 2.8.13
Please help
Solution 1:[1]
For me it worked by just logging into my repository from ssh >> ssh [email protected] It connected as the repository key were already in my computer. Then , git pushed my code to master >> git push origin master
Solution 2:[2]
I use VSCode. I got this error today when I tried to push my repository to GitHub:
! [remote rejected] master -> master (Internal Server Error)
error: failed to push some refs to 'https://github.com/xxx/yyy.git'
It happened several times. Then I just pulled the repository and then pushed it again and the problem resolved.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Anish Perumpilly |
| Solution 2 | alvand1399 |
