# HG changeset patch # User Anton Shestakov # Date 1648382523 -10800 # Node ID aa9b0d8f268e8696e335e33be18ba16d3a6afdd6 # Parent 2ec9c87e85746ba0f5f564e471f420019cfbb7a7 precheck: raise InputError, like the current upstream version diff -r 2ec9c87e8574 -r aa9b0d8f268e hgext3rd/evolve/rewriteutil.py --- a/hgext3rd/evolve/rewriteutil.py Sat Mar 19 19:13:00 2022 +0300 +++ b/hgext3rd/evolve/rewriteutil.py Sun Mar 27 15:02:03 2022 +0300 @@ -68,7 +68,7 @@ if node.nullrev in revs: msg = _(b"cannot %s the null revision") % (action) hint = _(b"no changeset checked out") - raise error.Abort(msg, hint=hint) + raise compat.InputError(msg, hint=hint) if any(util.safehasattr(r, 'rev') for r in revs): msg = b"rewriteutil.precheck called with ctx not revs" repo.ui.develwarn(msg) @@ -78,13 +78,13 @@ summary = _formatrevs(repo, publicrevs) msg = _(b"cannot %s public changesets: %s") % (action, summary) hint = _(b"see 'hg help phases' for details") - raise error.Abort(msg, hint=hint) + raise compat.InputError(msg, hint=hint) newunstable = disallowednewunstable(repo, revs) if newunstable: msg = _(b"%s will orphan %i descendants") msg %= (action, len(newunstable)) hint = _(b"see 'hg help evolution.instability'") - raise error.Abort(msg, hint=hint) + raise compat.InputError(msg, hint=hint) allowdivergence = compat.isenabled(repo, compat.allowdivergenceopt) if allowdivergence: return @@ -111,7 +111,7 @@ b'overwrite this check') % (base, otherdiv, localdiv) hint = _(b"see 'hg help evolution.instability' for details " b"on content-divergence") - raise error.Abort(msg, hint=hint) + raise compat.InputError(msg, hint=hint) def bookmarksupdater(repo, oldid, tr): """Return a callable update(newid) updating the current bookmark