git review sometimes causes unpacker error for Missing tree
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
git-review |
New
|
Undecided
|
Unassigned |
Bug Description
This is apparently a bug in JGit (implemented in gerrit), but the simplest workaround requires change on the git-review side.
Behaviour:
* Occasionnal failure on "git review" command can prevent push for revs.
### snip ###
git review
error: unpack failed: error Missing tree 99af9575b7587a7
fatal: Unpack error, check server log
To ssh://<email address hidden>
! [remote rejected] HEAD -> refs/publish/
error: failed to push some refs to 'ssh://<email address hidden>
### snap ###
It is related to buggy support of git "thin" optimization in JGit implementation in gerrit.
ref:
https:/
https:/
A simple workaround is to use "git push --no-thin", so allowing that option to be configured as default in git-review.conf would allow a workaround.
Created a patch (and pull request to upstream)
See it in action here: git-review/ git-review. conf
<pre>
$ grep disablethinpush ~/.config/
disablethinpush = true
$ git review -v publish/ master
[...]
2014-06-20 11:47:22.483602 Running: git push --no-thin origin HEAD:refs/
[...]
rm ~/.config/ git-review/ git-review. conf
$ git review -v --no-thin publish/ master
[...]
2014-06-20 11:55:57.272656 Running: git push --no-thin origin HEAD:refs/
[...]
$ git review -v publish/ master
[...]
2014-06-20 11:57:13.375985 Running: git push origin HEAD:refs/
[...]
</pre>