~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/errors.py

merge

Show diffs side-by-side

added added

removed removed

Lines of Context:
174
174
        self.branch = branch
175
175
 
176
176
 
 
177
class NoSuchId(BzrNewError):
 
178
    """The file id %(file_id)s is not present in the tree %(tree)s."""
 
179
    
 
180
    def __init__(self, tree, file_id):
 
181
        BzrNewError.__init__(self)
 
182
        self.file_id = file_id
 
183
        self.tree = tree
 
184
 
 
185
 
177
186
class NoWorkingTree(BzrNewError):
178
187
    """No WorkingTree exists for %(base)s."""
179
188
    
969
978
        DependencyNotPresent.__init__(self, 'paramiko', error)
970
979
 
971
980
 
 
981
class PointlessMerge(BzrNewError):
 
982
    """Nothing to merge."""
 
983
 
 
984
 
972
985
class UninitializableFormat(BzrNewError):
973
986
    """Format %(format)s cannot be initialised by this version of bzr."""
974
987
 
977
990
        self.format = format
978
991
 
979
992
 
 
993
class BadConversionTarget(BzrNewError):
 
994
    """Cannot convert to format %(format)s.  %(problem)s"""
 
995
 
 
996
    def __init__(self, problem, format):
 
997
        BzrNewError.__init__(self)
 
998
        self.problem = problem
 
999
        self.format = format
 
1000
 
 
1001
 
980
1002
class NoDiff(BzrNewError):
981
1003
    """Diff is not installed on this machine: %(msg)s"""
982
1004
 
1135
1157
        BzrNewError.__init__(self)
1136
1158
 
1137
1159
 
 
1160
class BadInventoryFormat(BzrNewError):
 
1161
    """Root class for inventory serialization errors"""
 
1162
 
 
1163
 
 
1164
class UnexpectedInventoryFormat(BadInventoryFormat):
 
1165
    """The inventory was not in the expected format:\n %(msg)s"""
 
1166
 
 
1167
    def __init__(self, msg):
 
1168
        BadInventoryFormat.__init__(self, msg=msg)
 
1169
 
 
1170
 
1138
1171
class UnknownSSH(BzrNewError):
1139
1172
    """Unrecognised value for BZR_SSH environment variable: %(vendor)s"""
1140
1173