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

Re: frustrated forensics: hard to find diff that undid a fix

From
Jonathan del Strother <maillist@steelskies.com>
Date
Mar 5, 2011, 10:00 UTC
Message-ID
<AANLkTinKmgnVN+zyhu03yiH4z2ucxqd9yBn+6f7ptnp0@mail.gmail.com>
In-Reply-To
<4D71D63E.3030907@gmail.com>
On 5 March 2011 06:20, Adam Monsen <haircut@gmail.com> wrote:
Show 32 quoted lines
> I made a fix a month ago on the master branch in a shared repo. A week
> later, a colleague did a merge that undid the fix. I didn't figure out
> the problem until just now because I'd been assuming the fix was still
> on master. I mean, if it wasn't, I should see a reverse patch using "git
> log -p master", right? Wrong. Turns out the fix was undone as part of
> merge conflict resolution (I think).
>
> Is there some way to include merge conflict resolutions in "git log -p"
> or "git show"? Apparently some important information can be hidden in
> the conflict resolution. Or, more likely, I just don't understand how
> this bit of git works.
>
> I also tried bisect and pickaxe. Bisect wrongly identified the first bad
> commit, and pickaxe just didn't see the change at all.
>
>    ~ * ~
>
> Here's some details in case anyone wants to (a) point out where I messed
> up or (b) help me avoid this kind of blunder in the future.
>
> 1. The repo is git://mifos.git.sourceforge.net/gitroot/mifos/head
> (mirror: https://github.com/mifos/head ). Branch master.
>
> 2. My commit 2a1ed0436 introduced a fix that includes the text
> "native2ascii". Shows up in "git log -p -1 2a1ed0436" and "git show
> 2a1ed0436". Life is good.
>
> 3. It appears that the merge commit 0f8132386 tossed my "native2ascii"
> fix. The only way I could figure out to actually visualize this is "git
> diff 58320586..0f813238".
>
> This took a while to figure out. Am I missing something obvious?

Seems like a bunch of people (myself included) have been tripped up by this behaviour in the past few months. Did something change to start this, or has it always been there?

-Jonathan
Previous: Adam MonsenNext: Jakub Narebski
Message 2 of 26 in “frustrated forensics: hard to find diff that undid a fix”
  1. Adam MonsenMar 5, 2011
  2. Jonathan del StrotherMar 5, 2011
  3. Jakub NarebskiMar 5, 2011
  4. Jonathan NiederMar 5, 2011
  5. Jeff KingMar 5, 2011
  6. Adam MonsenMar 5, 2011
  7. 0/2 improve combined diff documentationAdam Monsen, Mar 5, 2011
  8. 1/2 documentation fix: git log -p does not imply -c.Adam Monsen, Mar 5, 2011
  9. Junio C HamanoMar 7, 2011
  10. Jeff KingMar 7, 2011
  11. Junio C HamanoMar 7, 2011
  12. Jeff KingMar 7, 2011
  13. Documentation fix: git log -p does not imply -c.Adam Monsen, Mar 7, 2011
  14. Junio C HamanoMar 8, 2011
  15. Documentation fix: git log -p does not imply -c.Adam Monsen, Mar 8, 2011
  16. Junio C HamanoMar 8, 2011
  17. Adam MonsenMar 8, 2011
  18. Junio C HamanoMar 9, 2011
  19. Adam MonsenMar 9, 2011
  20. SubmittingPatches: clean up commit message tipsAdam Monsen, Mar 9, 2011
  21. Junio C HamanoMar 9, 2011
  22. diff format documentation: clarify --cc and -cAdam Monsen, Mar 8, 2011
  23. diff format documentation: clarify --cc and -cAdam Monsen, Mar 8, 2011
  24. Jeff KingMar 8, 2011
  25. 2/2 English grammar fixes for combined diff doc.Adam Monsen, Mar 5, 2011
  26. Martin von ZweigbergkMar 5, 2011

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.