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

Re: [PATCH v2 3/4] fast-export: don't handle uninteresting refs

From
Felipe Contreras <felipe.contreras@gmail.com>
Date
Oct 31, 2012, 02:22 UTC
Message-ID
<CAMP44s1EX8AJgFyOjbr0v5mrQooCwQ_gbr2HYf32qwU_Xf7HfA@mail.gmail.com>
In-Reply-To
<20121031015103.GA15167@elie.Belkin>
On Wed, Oct 31, 2012 at 2:51 AM, Jonathan Nieder <jrnieder@gmail.com> wrote:
Show 36 quoted lines
> Felipe Contreras wrote:
>
>>                                                    It's not my job to
>> explain to you that 'git fast-export' doesn't work this way, you have
>> a command line to type those commands and see for yourself if they do
>> what you think they do with a vanilla version of git. That's exactly
>> what I did, to make sure I'm not using assumptions as basis  for
>> arguing, it took me a few minutes.
>
> Well no, when I run "git blame" 10 years down the line and do not
> understand what your code is doing, it is not at all reasonable to
> expect me to checkout the parent commit, get it to compile with a
> modern toolchain, and type those commands for myself.
>
> Instead, the commit message should be self-contained and explain what
> the patch does.
>
> That has multiple parts:
>
>  - first, what the current behavior is
>
>  - second, what the intent behind the current behavior is.  This is
>    crucial information because presumably we want the change not to
>    break that.
>
>  - third, what change the patch makes
>
>  - fourth, what the consequences of that are, in terms of new use
>    cases that become possible and old use cases that become less
>    convenient
>
>  - fifth, optionally, how the need for this change was discovered
>    (real-life usage, code inspection, or something else)
>
>  - sixth, optionally, implementation considerations and alternate
>    approaches that were discarded

I don't see any "Explain in detail what different commands do, even if they are irrelevant to the patch in question because someone might think they would get broken by this patch when in fact they wouldn't", that might belong in the discussion, but not in the commit message, and certainly not in the form of any entitlement.

Again, it's _your_ responsibility to make sure the commands you say might get broken do actually work with your current git, it's not mine to run them for you, even though that's exactly what I did, because I'm interested in getting things correctly on record.

And FTR, since you removed it, here is what I proposed to add to the commit message:

--- The reason this happens is that before traversing the commits, fast-export checks if any of the refs point to the same object, and any duplicated ref gets added to a list in order to issue 'reset' commands after the traversing. Unfortunately, it's not even checking if the commit is flagged as UNINTERESTING. The fix of course, is to do precisely that. ---

With that, all the points above are tackled, except fourth, because there aren't any.

Cheers.
-- 
Felipe Contreras
Previous: Jonathan NiederNext: Jonathan Nieder
Message 25 of 29 in “Re: [PATCH v2 4/4] fast-export: make sure refs are updated properly”
  1. Sverre RabbelierOct 30, 2012
  2. Felipe ContrerasOct 30, 2012
  3. Sverre RabbelierOct 30, 2012
  4. Felipe ContrerasOct 30, 2012
  5. Jonathan NiederOct 30, 2012
  6. Felipe ContrerasOct 30, 2012
  7. Sverre RabbelierOct 30, 2012
  8. Felipe ContrerasOct 30, 2012
  9. Sverre RabbelierOct 30, 2012
  10. Felipe ContrerasOct 30, 2012
  11. Jonathan NiederOct 30, 2012
  12. Jonathan NiederOct 30, 2012
  13. Jonathan NiederOct 30, 2012
  14. Felipe ContrerasOct 30, 2012
  15. Felipe ContrerasOct 30, 2012
  16. Jonathan NiederOct 30, 2012
  17. Felipe ContrerasOct 30, 2012
  18. Jonathan NiederOct 30, 2012
  19. Felipe ContrerasOct 30, 2012
  20. Jonathan NiederOct 30, 2012
  21. Felipe ContrerasOct 31, 2012
  22. Jonathan NiederOct 31, 2012
  23. Felipe ContrerasOct 31, 2012
  24. Jonathan NiederOct 31, 2012
  25. Felipe ContrerasOct 31, 2012
  26. Jonathan NiederOct 31, 2012
  27. Felipe ContrerasOct 31, 2012
  28. Jonathan NiederOct 31, 2012
  29. Johannes SchindelinOct 30, 2012

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.