Mercurial > hgsubversion
changeset 221:ced45b753ba7
util: better error messages when finding svn parent of a revision.
author | Augie Fackler <durin42@gmail.com> |
---|---|
date | Sat, 28 Mar 2009 17:59:55 -0500 |
parents | 06eb60f9a026 |
children | f2c65dd3d5c0 |
files | util.py |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/util.py +++ b/util.py @@ -3,6 +3,7 @@ import shutil from mercurial import hg from mercurial import node +from mercurial import util svn_subcommands = { } def register_subcommand(name): @@ -94,7 +95,8 @@ def outgoing_revisions(ui, repo, hg_edit and sourcerev.node() != node.nullid): outgoing_rev_hashes.append(sourcerev.node()) sourcerev = sourcerev.parents() - assert len(sourcerev) == 1 + if len(sourcerev) != 1: + raise util.Abort("Sorry, can't find svn parent of a merge revision.") sourcerev = sourcerev[0] if sourcerev.node() != node.nullid: return outgoing_rev_hashes