Delta Debugging / git bisect

Thu, 23. Jul 2009

Categories: en development Tags: bisect Delta Debugging Eclipse git piccolo2d

Just had the problem โ€“ which of the last 40+ commits broke a certain feature in Piccolo2D rev550. As I used git as a svn proxy before, I remembered having heard of it’s binary-search delta-debugging feature.

So I started my first git bisect session:

  1. go back fairly far (git checkout 9377e6a0c6e9bcdff1803f18918e8a1a9282a4ee, Eclipse Refresh, try, fine!),
  2. start bisecting (doing each step: Eclipse->Refresh, Eclipse->Project->Clean, Try it out):
 1(master) $ git bisect start
 2(master|BISECTING) $ git bisect bad
 3(master|BISECTING) $ git bisect good 9377e6a0c6e9bcdff1803f18918e8a1a9282a4ee
 4Bisecting: 47 revisions left to test after this (roughly 6 steps)
 5[484ba591db63f6f476511787a5156cdaeb51889c] Fixed Issue 100; Plastered PInputEvent...
 6(484ba59...|BISECTING) $ git bisect good
 7Bisecting: 23 revisions left to test after this (roughly 5 steps)
 8[fa515a6d0eb5ce23d3e47df5e5b4e81e94fdfa81] Added tests for PBasicInputEventHandler
 9(fa515a6...|BISECTING) $ git bisect good
10Bisecting: 11 revisions left to test after this (roughly 4 steps)
11[6e496e12219346e856c8c519c29fedab3f196e35] Cleaned up PNavigationEventhandler.  R...
12(6e496e1...|BISECTING) $ git bisect bad
13Bisecting: 5 revisions left to test after this (roughly 3 steps)
14[c591c3098e6268cfc90fcb84672d642b0878a4b7] Removed some unnecessary imports from...
15(c591c30...|BISECTING) $ git bisect bad
16Bisecting: 2 revisions left to test after this (roughly 2 steps)
17[f3ca00181f2512b10bf12204395ad99f3d474f00] #84 added developers.
18(f3ca001...|BISECTING) $ git bisect good
19Bisecting: 1 revisions left to test after this (roughly 1 steps)
20[99e495ec4fc54b0f3a36ffd3b605f8a27bd86cdf] Refactored mousePressed and mouseRelease...
21(99e495e...|BISECTING) $ git bisect bad
22Bisecting: 0 revisions left to test after this (roughly 0 steps)
23[3f0c21d7cb88e696c23d4058acb708898bb60363] Just updated my contact info in the Maven...
24(3f0c21d...|BISECTING) $ git bisect good
2599e495ec4fc54b0f3a36ffd3b605f8a27bd86cdf is first bad commit
26commit 99e495ec4fc54b0f3a36ffd3b605f8a27bd86cdf
27Author:
28Date:   Mon Jul 20 15:02:56 2009 +0000
29
30    Refactored mousePressed and mouseReleased so that code common to each is now in a hel...
31
32    git-svn-id: https://piccolo2d.googlecode.com/svn/piccolo2d.java/trunk@524 aadc08cf-13...
33
34:040000 040000 b6c487cfdbe4df04947923af5fd05c45aa2ad38d 4dcd8070206a34a2d4037c3d90409ff1e...
35(3f0c21d...|BISECTING) $ git bisect reset
36Previous HEAD position was 3f0c21d... Just updated my contact info in the Maven Config File.
37Switched to branch 'master'
  1. done, got the fishy commit! (524)

P.S.: I cut the long lines, git spits them out in full, naturally.