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

Re: [PATCH 1/2] repository: make repo_clear() idempotent

From
Patrick Steinhardt <ps@pks.im>
Date
Sep 3, 2026, 05:15 UTC
Message-ID
<apkCe9CKvYvM6Hy9@pks.im>
In-Reply-To
<xmqqpkyvk45f.fsf@gitster.g>
On Wed, Sep 02, 2026 at 09:29:48AM -0700, Junio C Hamano wrote:
Show 9 quoted lines
> Patrick Steinhardt <ps@pks.im> writes:
> 
> > I was at one point wondering whether the parsed object pool should
> > really be an implementation detail of the object database -- parsing
> > objects should not have to depend on the repository, ...
> 
> We need to be a bit careful here, as the above directly contradicts
> our earlier design choice to have things like hash algorithm as
> properties of a repository instance.

Yeah, true. The question though is whether it really makes sense to always propagate down the full repository, or whether we should instead propagate only what matters. We do of course require the hash algorithm (and potentially the compatibility hash algorithm) in these subsystems, but propagating these two pieces of information might be the saner approach compared to always making the full repository available.

In any case, I eventually discarded the above idea anyway.
Patrick
Previous: Junio C HamanoNext: Jeff King
Message 7 of 9 in “fix a leak in submodule error path”
  1. 0/2 fix a leak in submodule error pathJeff King, Sep 2, 2026
  2. 1/2 repository: make repo_clear() idempotentJeff King, Sep 2, 2026
  3. Jeff KingSep 2, 2026
  4. Jeff KingSep 2, 2026
  5. Patrick SteinhardtSep 2, 2026
  6. Junio C HamanoSep 2, 2026
  7. Patrick SteinhardtSep 3, 2026
  8. 2/2 submodule--helper: free URL when repository setup failsJeff King, Sep 2, 2026
  9. Patrick SteinhardtSep 2, 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.