1

Github started rejecting my attempts to push my latest commits. I'm not sure why; can you please help? I'm just a user of Git, I don't know much about it. Here's the response to git push -u origin master:

Counting objects: 49, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (33/33), done.
Writing objects: 100% (49/49), 80.45 KiB | 40.23 MiB/s, done.
Total 49 (delta 24), reused 38 (delta 13)
fatal: The remote end hung up unexpectedly
fatal: The remote end hung up unexpectedly

I have to set the origin because I removed it earlier (in my attempt to solve this problem) and haven't successfully pushed since. Thirty minutes later I get a rather different response:

Counting objects: 49, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (33/33), done.
Writing objects: 100% (49/49), 80.45 KiB | 40.23 MiB/s, done.
Total 49 (delta 24), reused 38 (delta 13)
remote: error: object 91c3c1b5b1c6f17f90fb71f0c17a1990456fcbb6: treeNotSorted: not properly sorted
remote: fatal: fsck error in packed object
error: remote unpack failed: index-pack abnormal exit
To github.com:globewalldesk/revuu.git
 ! [remote rejected] master -> master (failed)
error: failed to push some refs to 'git@github.com:globewalldesk/revuu.git'

Here are some notes that might help troubleshoot:

  • I've been doing a lot of command line renaming and moving of directories. This has involved quite a bit of adding stuff to .gitignore and git rm --cache <foo>. I just did that willy-nilly...
  • When troubleshooting, I tried running git fsck --full and got this error:

    Checking object directories: 100% (256/256), done. error in tree 91c3c1b5b1c6f17f90fb71f0c17a1990456fcbb6: treeNotSorted: not properly sorted Checking objects: 100% (621/621), done.```

  • Also when troubleshooting, I have tried running git gc --prune="0 days"--no effect.
  • My "local" repo is actually in a cloud service. I've been switching back and forth between machines to work on it (this shouldn't matter, should it? Git seems to behave the same way regardless of the machine). I've been switching many wi-fi networks as I've traveled hither and yon. Didn't happen until after I got on my laptop and on a different wi-fi network... I tried switching to my iPhone's personal hotspot & Verizon; no dice.
  • I also tried changing my origin to https. Also removed the origin and reset it to ssh. No effect.
  • One answer suggests I use something called "git-repair" but this appears to be a Haskell script and I don't want to go the trouble of installing that if I don't have to.
  • Tried running git config --global http.postBuffer 524288000. No effect.
  • Repo here if that helps.
  • My Ruby script has been making and deleting lots of .tar files.
  • Result of git remote -v:

    origin git@github.com:globewalldesk/revuu.git (fetch) origin git@github.com:globewalldesk/revuu.git (push) origin-https https://github.com/globewalldesk/revuu.git (fetch) origin-https https://github.com/globewalldesk/revuu.git (push)

What else do I need to post to help figure this out?

globewalldesk
  • 544
  • 1
  • 3
  • 18
  • 1
    Github has been behaving a little strange since yesterday. See https://status.github.com/messages. Check if your issue is not related. – HariUserX Oct 23 '18 at 04:03
  • The latest message of theirs is that everything is operating normally; but thanks for the tip. I didn't even think that it might be their fault! – globewalldesk Oct 23 '18 at 04:06

1 Answers1

2

After the recent GitHub outage (only very recently resolved), try as a test to:

  • clone the repo again in a new location (either on your local machine or on your cloud)
  • report a new commit there
  • git push it
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • Well, it's accepted. I'm sure this means there's a straightforward solution. So... what is it? :-) – globewalldesk Oct 23 '18 at 04:53
  • 1
    @globewalldesk for now, the "solution" is making tests to see if your issue persists. If it does, it would need to be reported to GitHub support in order for GitHub to investigate and ascertain if it is related to their recent outage. – VonC Oct 23 '18 at 04:56
  • Update: I pulled down the latest "change," which resulted in an unfamiliar sort of merge requirement; after doing that, I tried pushing again, and got the same sort of error message, with "treeNotSorted" and "fsck error in packed object," etc. – globewalldesk Oct 23 '18 at 05:12
  • @globewalldesk did you pull it on your existing repo, or tried with a new cloned instance? – VonC Oct 23 '18 at 05:15
  • I pulled the old repo with the one edit (which was then immediately reverted) down into my existing repo. I was thinking that maybe I can just, you know, copy all my files into the local directory that works, and see if I can use that. I mean, maybe the git info for the original local directory is messed up. (Sorry, I don't know the jargon; the index might be messed up?) – globewalldesk Oct 23 '18 at 05:17
  • @globewalldesk Exactly: "the index might be messed up", which is why I was suggesting try and work on a new cloned repo instead of the current one. – VonC Oct 23 '18 at 05:18
  • Oh, I see. Couldn't I just remove all the git info from the existing local repo, then set a new upstream origin? – globewalldesk Oct 23 '18 at 05:20
  • @globewalldesk to set a new upstream, you would need "all the git info". For testing, it is easier to clone, make a new commit, and see if a push succeeds. – VonC Oct 23 '18 at 05:23
  • I ended up having to merge a whole bunch of stuff by hand, but it's all done! Whew--I still don't know what I did wrong, if anything. Anyway, my work is saved to Github! https://github.com/globewalldesk/revuu – globewalldesk Oct 23 '18 at 06:01