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

Re: git clone --shallow-since can result in inconsistent shallow clones

From
Jeff King <peff@peff.net>
Date
Aug 25, 2020, 19:51 UTC
Message-ID
<20200825195148.GC1419759@coredump.intra.peff.net>
In-Reply-To
<CAPSG9dZV2EPpVKkOMcjv5z+NF7rUu=V-ZkZNx47rCv122HsiKg@mail.gmail.com>
On Tue, Aug 25, 2020 at 11:38:04AM -0700, Nelson Elhage wrote:
Show 7 quoted lines
> It's unfortunately a bit unclear to me what _should_ happen here. We
> really want a way to mark `89ea0c5` as "partially-shallow", and send
> its second parent, but not its first parent, but shallowness is a
> property of an entire commit, not of a specific commit/parent
> relationship. However, it'd be nice if we at least ended up with a
> consistent state, instead of with a repository with invalid `shallow`
> marks.
I think this is the same issue I reported recently here:
  https://lore.kernel.org/git/20200721160643.GA3288097@coredump.intra.peff.net/

AFAICT the shallow feature is just defective and can't accurately represent this situation. Unfortunately nobody seemed to have any bright ideas, and the developer who implemented most of the shallow features (including shallow-since) is no longer active.

So I suspect it is fixable, but probably requires somebody to get pretty familiar with the shallow code, and propose a fix that involves both code and a protocol change.

-Peff
Previous: Nelson Elhage
Message 2 of 2 in “git clone --shallow-since can result in inconsistent shallow clones”
  1. Nelson ElhageAug 25, 2020
  2. Jeff KingAug 25, 2020

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.