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

Re: Is my repository broken?

From
Julian Phillips <julian@quantumfyre.co.uk>
Date
Apr 8, 2008, 23:21 UTC
Message-ID
<Pine.LNX.4.64.0804090003480.10813@kaos.quantumfyre.co.uk>
In-Reply-To
<20080408225522.GD10274@spearce.org>
On Tue, 8 Apr 2008, Shawn O. Pearce wrote:
Show 12 quoted lines
> Julian Phillips <julian@quantumfyre.co.uk> wrote:
>> [...] In particular I had a number of commits with an empty ident [...]
> ...
>> Also, shouldn't fast-import be imposing the same restrictions on what you
>> are allowed to commit that the main git tools do?  If not, are such
>> restrictions documented so that I can apply them in my conversion script?
>
> Hmm, no.  fast-import allows what the generalized data model permits
> in the object store, its really plumbing.  If you are feeding it
> an input stream that creates data that isn't compliant with what
> the higher level VCS porcelain wants, well, all I can say is "don't
> do that".
Well, the 16 parent limit is enforced in builtin-commit-tree.c, and the 
commit-tree command is listed as plumbingmanipulators in command-list.txt 
- and the #define line actually blames all the way back to Linus' original 
commit.  So that's not really a porcelain thing ;), but ... *shrugs*
> The fast-import manual specifically warns in the "merge" command
> documentation that you may not want to use more than 15 merge
> commands, as it can create a commit that other tools based around
> git won't like.  But we still let you do it.

Ok, so the answer is "read the manpage" ... that's what I get for spending so long playing with fast-import that I don't read the manpage anymore (I found the syntax description in fast-import.c a more useful reference) ... ho hum.

> We also still let you create a commit with duplicate parents.

Well - that certainly shouldn't be happening - I remebered to check for that one.

Show 5 quoted lines
> Some tools (gitk) have had issues with that in the past, but many of
> them have been fixed after a fast-import result was used with them.
>> From a VCS point of view its silly to list the same ancestor twice.
> But from an object model point of view, it may make sense if you
> were building something else on top of the core plumbing.

Would it make sense perhaps for fast-import to warn about (or even error out on) such things unless you tell it not to? Most people would probably want to know if they were creating a repository that wasn't going to play nice with git's main tool suite? (I didn't realise that I _was_ creating

>16 way merges until filter-branch told me).
> The same holds true for the empty ident.
Ok - but I can't even find a note in the manpage for this one ...
-- 
Julian

  ---
I thought there was chocolate inside ... Well, why was it wrapped in foil?

 		-- Homer Simpson
 		   Mr. Plow
Previous: Shawn O. PearceNext: Junio C Hamano
Message 4 of 6 in “Is my repository broken?”
  1. Julian PhillipsApr 8, 2008
  2. Junio C HamanoApr 8, 2008
  3. Shawn O. PearceApr 8, 2008
  4. Julian PhillipsApr 8, 2008
  5. Junio C HamanoApr 9, 2008
  6. Julian PhillipsApr 9, 2008

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.