162
162
class InvalidRevisionId(BzrNewError):
163
163
"""Invalid revision-id {%(revision_id)s} in %(branch)s"""
164
165
def __init__(self, revision_id, branch):
165
166
# branch can be any string or object with __str__ defined
166
167
BzrNewError.__init__(self)
304
305
(use bzr checkout if you wish to build a working tree): %(path)s"""
308
class AtomicFileAlreadyClosed(PathError):
309
"""'%(function)s' called on an AtomicFile after it was closed: %(path)s"""
311
def __init__(self, path, function):
312
PathError.__init__(self, path=path, extra=None)
313
self.function = function
316
class InaccessibleParent(PathError):
317
"""Parent not accessible given base %(base)s and relative path %(path)s"""
319
def __init__(self, path, base):
320
PathError.__init__(self, path)
307
324
class NoRepositoryPresent(BzrNewError):
308
325
"""No repository present: %(path)r"""
309
326
def __init__(self, bzrdir):
1045
1062
"""Not a bzr revision-bundle: %(text)r"""
1047
1064
def __init__(self, text):
1051
class BadBundle(Exception): pass
1054
class MalformedHeader(BadBundle): pass
1057
class MalformedPatches(BadBundle): pass
1060
class MalformedFooter(BadBundle): pass
1065
BzrNewError.__init__(self)
1069
class BadBundle(BzrNewError):
1070
"""Bad bzr revision-bundle: %(text)r"""
1072
def __init__(self, text):
1073
BzrNewError.__init__(self)
1077
class MalformedHeader(BadBundle):
1078
"""Malformed bzr revision-bundle header: %(text)r"""
1080
def __init__(self, text):
1081
BzrNewError.__init__(self)
1085
class MalformedPatches(BadBundle):
1086
"""Malformed patches in bzr revision-bundle: %(text)r"""
1088
def __init__(self, text):
1089
BzrNewError.__init__(self)
1093
class MalformedFooter(BadBundle):
1094
"""Malformed footer in bzr revision-bundle: %(text)r"""
1096
def __init__(self, text):
1097
BzrNewError.__init__(self)
1101
class UnsupportedEOLMarker(BadBundle):
1102
"""End of line marker was not \\n in bzr revision-bundle"""
1105
BzrNewError.__init__(self)
1108
class GhostRevision(BzrNewError):
1109
"""Revision {%(revision_id)s} is a ghost."""
1111
def __init__(self, revision_id):
1112
BzrNewError.__init__(self)
1113
self.revision_id = revision_id