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

Re: What's cooking in git.git (Jan 2024, #01; Tue, 2)

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 16, 2024, 22:45 UTC
Message-ID
<xmqqfrywyk16.fsf@gitster.g>
In-Reply-To
<Zabr1Glljjgl/UUB@nand.local>
Taylor Blau <me@ttaylorr.com> writes:
Show 14 quoted lines
> OK, everything seems fine thus far, until we inspect the value of
> g->bloom_filter_settings, which is NULL, becuase of this hunk from
> commit-graph.c::graph_read_bloom_data():
>
>     if (hash_version != 1)
>       return 0;
>
> which terminates the function before we assign g->bloom_filter_settings
> for the existing (written with v2 Bloom filters) graph layer.
>
> I don't think that there is a way to fix this in a backwards compatible
> way, but I'm comfortable with that in this instance since we don't
> expect users to upgrading to v2 Bloom filters and then writing new graph
> layers using a non-v2 compatible version of Git.

A big red button solution to avoid this would be to uprev the repository format version once you start writing v2 Bloom filters anywhere in the layers. That way, existing Git clients would not be able to touch it. I do not know if the cure is more severe than the disease in that case, though.

In any case, at least, we should be able to prepare the code that we teach to grok v2 today so that they do not trigger the same segfault when they see a commit graph layer containing v3 Bloom filters (or later). Then we won't have to have the same conversation when we somehow need to update Bloom filters again.

Previous: Taylor BlauNext: Taylor Blau
Message 18 of 20 in “What's cooking in git.git (Jan 2024, #01; Tue, 2)”
  1. Junio C HamanoJan 3, 2024
  2. Patrick SteinhardtJan 3, 2024
  3. Jeff KingJan 3, 2024
  4. Junio C HamanoJan 3, 2024
  5. Jeff KingJan 5, 2024
  6. Junio C HamanoJan 5, 2024
  7. René ScharfeJan 3, 2024
  8. Taylor BlauJan 3, 2024
  9. Junio C HamanoJan 3, 2024
  10. SZEDER GáborJan 13, 2024
  11. Taylor BlauJan 13, 2024
  12. SZEDER GáborJan 13, 2024
  13. Taylor BlauJan 16, 2024
  14. SZEDER GáborFeb 25, 2024
  15. Taylor BlauFeb 26, 2024
  16. SZEDER GáborJan 13, 2024
  17. Taylor BlauJan 16, 2024
  18. Junio C HamanoJan 16, 2024
  19. Taylor BlauJan 16, 2024
  20. Junio C HamanoJan 16, 2024

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.