comparison mercurial/error.py @ 27515:f8142cb77b1e

error: refactor OutOfBandError to inherit from HintException
author timeless <timeless@mozdev.org>
date Wed, 23 Dec 2015 17:38:24 +0000
parents 039a53c87370
children 1c1216182dc1
comparison
equal deleted inserted replaced
27514:311eddddca49 27515:f8142cb77b1e
76 """Raised when an EOF is received for a prompt""" 76 """Raised when an EOF is received for a prompt"""
77 def __init__(self): 77 def __init__(self):
78 from .i18n import _ 78 from .i18n import _
79 Abort.__init__(self, _('response expected')) 79 Abort.__init__(self, _('response expected'))
80 80
81 class OutOfBandError(Exception): 81 class OutOfBandError(HintException):
82 """Exception raised when a remote repo reports failure""" 82 """Exception raised when a remote repo reports failure"""
83
84 def __init__(self, *args, **kw):
85 Exception.__init__(self, *args)
86 self.hint = kw.get('hint')
87 83
88 class ParseError(Exception): 84 class ParseError(Exception):
89 """Raised when parsing config files and {rev,file}sets (msg[, pos])""" 85 """Raised when parsing config files and {rev,file}sets (msg[, pos])"""
90 86
91 class UnknownIdentifier(ParseError): 87 class UnknownIdentifier(ParseError):