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

Re: [PATCH 4/5] allow deepening of a shallow repository

From
Junio C Hamano <junkio@cox.net>
Date
Nov 17, 2006, 09:09 UTC
Message-ID
<7vy7qaqw12.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<Pine.LNX.4.63.0611141150010.13772@wbgn013.biozentrum.uni-wuerzburg.de>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> Yes. Somehow, an important part of unregister_shallow() went missing (yet 
> another proof that my poor-man's-StGit does not always work). I think that 
> the "object->parsed = 0;" should go into unregister_shallow() like this:

That does not fly so well. Your fetch-pack.c does this in find_common() and dropping the parsed flag inside unregister causes it to be parsed again later with its true parents, which defeats what the commented part of the code wanted to do.

	if (!lookup_object(sha1))
		die("object not found: %s", line);
	/* make sure that it is parsed as shallow */
	parse_object(sha1);
	if (unregister_shallow(sha1))
		die("no shallow found: %s", line);
	continue;

Although I am reasonably sure we can eventually make it work, it is very subtle and fragile -- somebody touching this code can easily break it. .

Previous: Johannes SchindelinNext: Johannes Schindelin
Message 4 of 7 in “allow deepening of a shallow repository”
  1. 4/5 allow deepening of a shallow repositoryJohannes Schindelin, Oct 30, 2006
  2. Junio C HamanoNov 14, 2006
  3. Johannes SchindelinNov 14, 2006
  4. Junio C HamanoNov 17, 2006
  5. Johannes SchindelinNov 17, 2006
  6. Junio C HamanoNov 17, 2006
  7. Johannes SchindelinNov 18, 2006

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.