I found the solution.
git fsck && git gc --prune=now
which leads to many errors like this one:
But it worked after reloading the IDE, here is the origin of this code: Why does git pull hang?