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

Re: [BUG] Geometric maintenance prunes commits without updating commit-graph

From
Patrick Steinhardt <ps@pks.im>
Date
Nov 19, 2026, 12:50 UTC
Message-ID
<av7wkQXxYrzAJInT@pks.im>
In-Reply-To
<ba964c70-60ab-4b7a-a0fa-6e028e401a09@wsoptics.de>
Hi,
On Thu, Nov 05, 2026 at 07:41:26AM +0100, Christoph Weiss wrote:
Show 6 quoted lines
> Hi,
> 
> After updating our internal Forgejo instance from 16 to 17, many of our
> repositories' health checks started failing.  This appears to be due to the
> update entailing a switch in Git from 2.52 to 2.54, which in turn changed
> the default maintenance strategy from `gc` to `geometric`.
thanks for the report, makes sense.

I think the way to fix this is to move generation of commit graphs into `odb_optimize()`, which would give us a lot more control over when exactly we generate them. And that would allow us to figure out whether we have discarded any objects in the first place, in which case we'd rewrite the commit graph.

That also aligns with my other in-flight patch series that makes commit graphs pluggable in the first place. Once they're an implementation deatil of the object database backend, it's only natural to also write them as part of `odb_optimize()`.

That means thought that I can only fix this once [1] has landed, as any changes I'd make to fix the reported issue would conflict. But once it did I'll send such a patch series.

Thanks!
Patrick
Previous: Christoph Weiss
Message 2 of 2 in “[BUG] Geometric maintenance prunes commits without updating commit-graph”
  1. Christoph WeissNov 5, 2026
  2. Patrick SteinhardtNov 19, 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.