git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: False alarms from git-fsck(1) about missing commits/trees pushed after the run started

From
Junio C Hamano <gitster@pobox.com>
Date
Feb 28, 2011, 16:23 UTC
Message-ID
<7vbp1wjffn.fsf@alter.siamese.dyndns.org>
In-Reply-To
<AANLkTimrgepw4r=z5na-d74XY67QuRRgFepWZh87xrCq@mail.gmail.com>
Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:
> But actually these things aren't missing. They were just pushed to the
> repo after the fsck run started.
>
> Is this a known limitation of git-fsck,...
Yes.

We validate the contents of the objects we find in the repository (we do this by directly visiting .git/objects/??/ and .git/objects/packs/ directories and validate the contents of even unreachable objects), mark their existence while doing so, and then traverse the reachability DAG from refs to find dangling & missing.

It always is possible to have objects we mark as reachable in the second phase that are not marked as existing in the first phase if you are actively adding objects to the repository (e.g. by pushing into it, by fetching into it, or by running "git add") while running fsck, as these new objects may not exist during the first phase but then later can become reachable by ref updates.

> ..., is it documented anywhere?
I don't know for sure but I doubt it; please make it so.
Previous: Ævar Arnfjörð Bjarmason
Message 2 of 2 in “False alarms from git-fsck(1) about missing commits/trees pushed after the run started”
  1. Ævar Arnfjörð BjarmasonFeb 28, 2011
  2. Junio C HamanoFeb 28, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.