unable to resolve reference 'refs/merge-requests/2477/head': reference broken code example
Example: git unable to update local ref
git gc --prune=now
git remote prune origin
rm .git/refs/remotes/origin/master
git fetch
git pull origin master
git gc --prune=now
git remote prune origin
rm .git/refs/remotes/origin/master
git fetch
git pull origin master