Search code examples
gitgithubclone

Issues cloning from Github


I'm getting this strange error message when trying to clone or pull from git. The strange thing is that me and a colleague previously had no issues with this. We then got two other team members to clone the repository and now suddenly me and the previous colleague continue to get these errors. The two new guys have no problem pulling/pushing and cloning. Suddenly the two original team members can't do anything.

I can't imagine what the two new members might have modified or changed, we're just doing straightforward things at the moment. Is it possibly an issue with GitHub and the previous team members accounts?

Cloning into test...
Enter passphrase for key '/c/Users/Rob/.ssh/id_rsa':
remote: Counting objects: 8685, done.
remote: Compressing objects: 100% (3737/3737), done.
remote: Total 8685 (delta 5005), reused 8490 (delta 4810)
Receiving objects: 100% (8685/8685), 239.92 MiB | 158 KiB/s, done.
Resolving deltas: 100% (5005/5005), done.
error: refs/remotes/origin/master does not point to a valid object!
error: Trying to write ref refs/heads/master with nonexistant object 3cad1d0fb95b397ae8ed4826e29073362e135e2f
fatal: Cannot update the ref 'HEAD'.
Unlink of file 'test/.git/objects/pack/pack-9bca633d2527e271701b07f92128b15a6396277a.idx' failed. Should I try again? (y/n)

UPDATE: I just tried setting up a new account on github and tried to clone again, but same issues, which I guess narrows it down to some kind of global setting I might have on github.


Solution

  • This ended up being a strange error with the git client, I re-installed and everything worked fine after that.