comparison mercurial/error.py @ 26692:8d1cfd77b64f

hook: raise a separate exception for when loading a hook fails For easier catching.
author Siddharth Agarwal <sid0@fb.com>
date Mon, 12 Oct 2015 18:49:23 -0700
parents 634666c48b7d
children 338af85109dd
comparison
equal deleted inserted replaced
26691:23c0da28c034 26692:8d1cfd77b64f
53 class InterventionRequired(Exception): 53 class InterventionRequired(Exception):
54 """Exception raised when a command requires human intervention.""" 54 """Exception raised when a command requires human intervention."""
55 55
56 class Abort(HintException): 56 class Abort(HintException):
57 """Raised if a command needs to print an error and exit.""" 57 """Raised if a command needs to print an error and exit."""
58 pass
59
60 class HookLoadError(Abort):
61 """raised when loading a hook fails, aborting an operation
62
63 Exists to allow more specialized catching."""
58 pass 64 pass
59 65
60 class HookAbort(Abort): 66 class HookAbort(Abort):
61 """raised when a validation hook fails, aborting an operation 67 """raised when a validation hook fails, aborting an operation
62 68