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

Re: [PATCH v3] git-p4: recover from inconsistent perforce history

From
Andrew Oakley <andrew@adoakley.name>
Date
May 10, 2020, 14:13 UTC
Message-ID
<20200510151354.16ce2ab1@ado-tr.home.arpa>
In-Reply-To
<CAE5ih793qKyOSE-hkOw7+nFmM3XTRxxrXv0FD2+WWXjGbVHkoQ@mail.gmail.com>

On Sun, 10 May 2020 13:03:11 +0100 Luke Diamand <luke@diamand.org> wrote:

Show 13 quoted lines
> Perforce changed their server to reject this kind of thing in the
> 2017.1 version:
> 
>     Bugs fixed in 2017.1
>     #1489051 (Job #2170) **
>        Submitting a file with the same name as an existing depot
>        directory path (or vice versa) will now be rejected.
> 
> (Of course people will still have damaged repos even today).
> 
> I tried your test with both the 2015.1 and the 2020.1 versions, and it
> worked in both cases - shouldn't it be impossible to get into the
> state that git-p4 now recovers from with a newer p4d?

Yes, there is an option in perforce (submit.collision.check) that stops new changelists from introducing this problem, and it is turned on by default. Unfortunately this option does *exactly* what the description says, so you can't delete a directory and replace it with a file in the same changelist - the delete has to happen first. It's not clear which behaviour is least bad.

The test case tries to turn the perforce option off so it works on both old and new server versions.

Thanks
Previous: Luke DiamandNext: Junio C Hamano
Message 3 of 4 in “git-p4: recover from inconsistent perforce history”
  1. git-p4: recover from inconsistent perforce historyAndrew Oakley, May 10, 2020
  2. Luke DiamandMay 10, 2020
  3. Andrew OakleyMay 10, 2020
  4. Junio C HamanoMay 10, 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.