equal
deleted
inserted
replaced
16 # Do not import anything here, please |
16 # Do not import anything here, please |
17 |
17 |
18 class Hint(object): |
18 class Hint(object): |
19 """Mix-in to provide a hint of an error |
19 """Mix-in to provide a hint of an error |
20 |
20 |
21 This should come first in the inheritance list to consume **kw and pass |
21 This should come first in the inheritance list to consume a hint and |
22 only *args to the exception class. |
22 pass remaining arguments to the exception class. |
23 """ |
23 """ |
24 def __init__(self, *args, **kw): |
24 def __init__(self, *args, **kw): |
25 super(Hint, self).__init__(*args) |
25 self.hint = kw.pop('hint', None) |
26 self.hint = kw.get('hint') |
26 super(Hint, self).__init__(*args, **kw) |
27 |
27 |
28 class RevlogError(Hint, Exception): |
28 class RevlogError(Hint, Exception): |
29 pass |
29 pass |
30 |
30 |
31 class FilteredIndexError(IndexError): |
31 class FilteredIndexError(IndexError): |