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

Re: [BUG] splitIndex with skipHash corrupts index and crashes status

From
Andy Koppe <andy.koppe@gmail.com>
Date
Nov 7, 2026, 21:55 UTC
Message-ID
<CAHWeT-abY9_OOji+WkL3_Rpnzy0xBh3MGQCnhuUO9Wdr1hJy0Q@mail.gmail.com>
In-Reply-To
<CAKrRMNpaBrOybe0hw_B+RTZ5GWeUASpR+sRte0OLL2x6xJba8g@mail.gmail.com>
On Sat, 7 Nov 2026 at 21:11, Tanga Joris wrote:
Show 19 quoted lines
> >   $ ls .git | grep index
> >   index
> >   sharedindex.0000000000000000000000000000000000000000
> >
> > Note the unexpected null OID.
>
> It seems to be caused by write_shared_index() naming the file after
> the shared index's trailing checksum. With index.skipHash, that
> checksum is written as zeros, so the file is named
> sharedindex.0000000000000000000000000000000000000000,
> which is the file you saw.
>
> The entries disappear because the split index then records a null
> base, and read_index_from() treats a null base as "no shared index"
> (read-cache.c:2381), so the entries stored in the shared index are
> lost.
>
> I'm working on a fix and would be more than happy to send it, unless
> you are already working on one.
Thank you very much for looking into this! I haven't dared wading into it.
Andy
Previous: Tanga JorisNext: Tanga Joris
Message 3 of 5 in “[BUG] splitIndex with skipHash corrupts index and crashes status”
  1. Andy KoppeNov 7, 2026
  2. Tanga JorisNov 7, 2026
  3. Andy KoppeNov 7, 2026
  4. Tanga JorisNov 7, 2026
  5. read-cache: do not skip the hash of the shared indexTanga Joris, Nov 8, 2026

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.