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

Re: git bisect Vs branch

From
GRGrégory Romé <gregory.rome@maxim-ic.com>
Date
Oct 23, 2009, 09:24 UTC
Message-ID
<4AE17645.2000408@maxim-ic.com>
In-Reply-To
<4AE16A82.1010103@viscovery.net>

Thanks even if that's what scared me :) The draw is very simple comparing to the reality (much more merge points) and rebase will require lot of conflicts resolutions but now I'm sure that's what I have to do.

Grégory
Johannes Sixt wrote:
Show 36 quoted lines
> Grégory Romé schrieb:
>> Thanks Santi but I have a problem, due to the fact that the commit which
>> has an impact on my code is in origin/master or first-origin/master
>>
>> When bisect checkout a commit from those branch I have none of my own
>> modifications... So I can' test if my code is good or bad excepted if I
>> can merge my commits in the bisect branch...
>>                                                    ᐁ
>> first-origin/master  *---A---------B----------------o------C-
>>                           \         \                       \
>> origin/master              ----------B'----------U-----------C'-
>>                                       \           \           \
>> master                                 ------------U'----------C''-
> 
> C" is the commit that merges upstream changes into your changes. You are
> saying that your changes alone (before the merge) are good, and that
> upstream before the merge is also good (since it doesn't contain your
> changes, it is good by definition, more or less). That indeed means that
> the merge commit is the first bad one; i.e., this is exactly the situation
> that the user manual describes.
> 
> You should do:
> 
>   $ git checkout -b tmp master   # master is at C"
>   $ git rebase origin/master
>   $ git bisect start tmp orgin/master
> 
> That is, you rebuild your history on top of origin/master in a linear
> fashion. (If you had merge conflicts in U', then you will see them again.)
> Then you bisect the linearized history. This will point you to the bad
> commit and you will understand what is going wrong.
> 
> With this new knowledge, go back to master (C") and fix the problem.
> 
> -- Hannes
> 
Previous: Johannes SixtNext: Daniel Barkalow
Message 5 of 7 in “git bisect Vs branch”
  1. Grégory RoméOct 22, 2009
  2. Santi BéjarOct 22, 2009
  3. Grégory RoméOct 23, 2009
  4. Johannes SixtOct 23, 2009
  5. Grégory RoméOct 23, 2009
  6. Daniel BarkalowOct 23, 2009
  7. Junio C HamanoOct 23, 2009

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.