Submitter | Mads Kiilerich |
---|---|
Date | Nov. 10, 2013, 5:58 p.m. |
Message ID | <a19429a57d1b9386eba4.1384106320@localhost.localdomain> |
Download | mbox | patch |
Permalink | /patch/2899/ |
State | Accepted |
Commit | 06ef32c3b4bb2974749eefa171434903fe887e46 |
Headers | show |
Comments
On Sun, 2013-11-10 at 18:58 +0100, Mads Kiilerich wrote: > # HG changeset patch > # User Mads Kiilerich <madski@unity3d.com> > # Date 1384105881 -3600 > # Sun Nov 10 18:51:21 2013 +0100 > # Branch stable > # Node ID a19429a57d1b9386eba4775929a4e82fd3070d74 > # Parent ba6486076429e5c20d910b8a5d4f8acf1e9dc1b1 > bisect: report "both good and bad" as such, not as "not directly related" Queued for stable, thanks.
Patch
diff --git a/mercurial/hbisect.py b/mercurial/hbisect.py --- a/mercurial/hbisect.py +++ b/mercurial/hbisect.py @@ -62,7 +62,8 @@ def bisect(changelog, state): badrev, ancestors = buildancestors(state['good'], state['bad']) bad = changelog.node(badrev) if not ancestors: # now we're confused - if len(state['bad']) == 1 and len(state['good']) == 1: + if (len(state['bad']) == 1 and len(state['good']) == 1 and + state['bad'] != state['good']): raise util.Abort(_("starting revisions are not directly related")) raise util.Abort(_("inconsistent state, %s:%s is good and bad") % (badrev, short(bad))) diff --git a/tests/test-bisect.t b/tests/test-bisect.t --- a/tests/test-bisect.t +++ b/tests/test-bisect.t @@ -280,7 +280,7 @@ skip $ hg bisect -r $ hg bisect -g tip $ hg bisect -b tip - abort: starting revisions are not directly related + abort: inconsistent state, 31:58c80a7c8a40 is good and bad [255] $ hg bisect -r