Mercurial > public > mercurial-scm > hg
diff hgext/rebase.py @ 33789:19f495fef0a3
rebase: change "result would have 3 parent" error message (BC)
The old error message "cannot use revision REV as base, result would have 3
parents" is confusing - why use REV as base? why add a new parent?.
This patch changes it to "cannot move parent", which seems better.
Differential Revision: https://phab.mercurial-scm.org/D342
author | Jun Wu <quark@fb.com> |
---|---|
date | Sat, 12 Aug 2017 21:01:06 -0700 |
parents | 0975506120fb |
children | 35fc5e919675 |
line wrap: on
line diff
--- a/hgext/rebase.py Mon Aug 14 07:02:38 2017 -0700 +++ b/hgext/rebase.py Sat Aug 12 21:01:06 2017 -0700 @@ -1091,10 +1091,9 @@ # /| # None of A and B will be changed to D and rebase fails. # A B D if set(newps) == set(oldps) and dest not in newps: - # The error message is for compatibility. It's a bit misleading - # since rebase is not supposed to add new parents. - raise error.Abort(_('cannot use revision %d as base, ' - 'result would have 3 parents') % rev) + raise error.Abort(_('cannot rebase %d:%s without ' + 'moving at least one of its parents') + % (rev, repo[rev])) repo.ui.debug(" future parents are %d and %d\n" % tuple(newps))