Skip to content
Snippets Groups Projects
Commit 5ced12cf authored by Martin von Zweigbergk's avatar Martin von Zweigbergk
Browse files

errors: raise InputError on bad revset to revrange() iff provided by the user

Most callers of `scmutil.revrange()` pass in a revset provided by the
user. If there are problems resolving that, it should result in an
`InputError` and exit code 10 (when using detailed exit
codes). However, there are also some callers that pass in revsets not
provided by the user. `InputError` is not appropriate in those
cases. This patch therefore introduces a wrapper around
`scmutil.revrange()` that simply converts the exception type. I put it
in `logcmdutil.py` since that seems to be the lowest-level module in
the (poorly defined) UI layer.

Differential Revision: https://phab.mercurial-scm.org/D11560
parent b067d22d
No related branches found
No related tags found
No related merge requests found
Showing with 56 additions and 50 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment