question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Dropwizard has a broken commit:

$ git clone https://github.com/dropwizard/dropwizard.git
Cloning into 'dropwizard'...
remote: Counting objects: 123311, done.
remote: Compressing objects: 100% (24/24), done.
remote: Total 123311 (delta 1), reused 0 (delta 0), pack-reused 123280
Receiving objects: 100% (123311/123311), 46.11 MiB | 1.71 MiB/s, done.
Resolving deltas: 100% (78597/78597), done.
$ cd dropwizard
$ git fsck
Checking object directories: 100% (256/256), done.
error in commit 6fbf9def0293986beb2547a671f46148a5d2faf7: badDate: invalid author/committer line - bad date
Checking objects: 100% (123311/123311), done.

The problem is that the commit has an uncorrect author field:

$ git show --format=raw 6fbf9def0293986beb2547a671f46148a5d2faf7
commit 6fbf9def0293986beb2547a671f46148a5d2faf7
tree a452806b01d6ebd7d28cc3c85451ae1485f07257
parent 662010f5206fbe3d5390760501a8f48ffa9602ac
parent 2b2c23d52f348a16d9644acd08339992dfeca011
author Coda Hale <coda.hale@gmail.com> <coda.hale@gmail.com> 1305038239 -0700
committer Coda Hale <coda.hale@gmail.com> <coda.hale@gmail.com> 1305038239 -0700

    Merge pull request #3 from tommorris/patch-1

    added link to example application repository from README

Expected is:

...
author Coda Hale <coda.hale@gmail.com> 1305038239 -0700
committer Coda Hale <coda.hale@gmail.com> 1305038239 -0700
...

I discovered this because I have the following sections in my .gitconfig to make sure that my checkouts are correct:

[transfer]
        fsckobjects = true
[fetch]
        fsckobjects = true
[receive]
        fsckObjects = true

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
ryankennedycommented, Apr 4, 2017

GitHub support confirmed that this has been around a while:

As you suspected, this issue is popping up because some new cloners who have fsckobjects enabled are noticing it. There is a malformed commit in the history, and unless you want to rewrite the history (unlikely), the only solution is for the cloners to disable fsckObjects.

To be clear, that malformed commit was already there, it wasn’t introduced when the repo was restored.

In case you’re curious, there’s an extra email address in the author and committer info:

$ git cat-file commit 6fbf9def0293986beb2547a671f46148a5d2faf7 | egrep ‘^(author|committer)’ author Coda Hale coda.hale@gmail.com coda.hale@gmail.com 1305038239 -0700 committer Coda Hale coda.hale@gmail.com coda.hale@gmail.com 1305038239 -0700 Let us know if you have any other questions.

I think rewriting history is going to be dicey at best, so I’m going to close this and we’ll just have to remember to let folks know.

1reaction
ryankennedycommented, Apr 4, 2017

Okay, that makes me feel slightly better, then. I’m guessing it’s unrelated to the repo deletion and has probably been around for a while. I guess we know what most contributors have fsckobjects set to. 😐

Having no real experience repairing git repos, I have no immediate suggestions for fixing. I’ll wait a little longer to see it GH support responds with any recommendations.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How can I fix a corrupted Git repository? - Stack Overflow
Create a backup copy of your corrupted repository. · Delete broken references: find .git/refs -size 0 -delete -print · Repair repository from ...
Read more >
Ubuntu Manpage: git-repair - Fix a broken git repository
git -repair is able to test itself, by making a temporary copy of the git reposiory it's run in, damaging it in random...
Read more >
Gitkab repocheck (git fsck) fails, but I don't know how to really ...
I have a self-hosted gitlab instance and suddenly one of my projects is sending emails telling me that the repo check is failing....
Read more >
Git - git-fsck Documentation
During fsck git may find issues with legacy data which wouldn't be generated by current versions of git, and which wouldn't be sent...
Read more >
git fsck fails with the same error for 3 different repositories
I'm running git fsck command on some repositories, and for 3 of them I got the same error:
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found