/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/bzr/inventory.py

  • Committer: Breezy landing bot
  • Author(s): Gustav Hartvigsson
  • Date: 2021-01-10 18:46:30 UTC
  • mfrom: (7526.1.1 brz-removed-api-doc)
  • mto: This revision was merged to the branch mainline in revision 7532.
  • Revision ID: breezy.the.bot@gmail.com-20210110184630-dxu0g9dqq020uiw6
Drop documentation for removed API API.

Merged from https://code.launchpad.net/~gustav-hartvigsson/brz/removed-api-doc/+merge/396033

Show diffs side-by-side

added added

removed removed

Lines of Context:
60
60
        self.name = name
61
61
 
62
62
 
 
63
class DuplicateFileId(errors.BzrError):
 
64
 
 
65
    _fmt = "File id {%(file_id)s} already exists in inventory as %(entry)s"
 
66
 
 
67
    def __init__(self, file_id, entry):
 
68
        errors.BzrError.__init__(self)
 
69
        self.file_id = file_id
 
70
        self.entry = entry
 
71
 
 
72
 
63
73
class InventoryEntry(object):
64
74
    """Description of a versioned file.
65
75
 
1131
1141
                new_entry = replacement
1132
1142
            try:
1133
1143
                self.add(new_entry)
1134
 
            except errors.DuplicateFileId:
 
1144
            except DuplicateFileId:
1135
1145
                raise errors.InconsistentDelta(new_path, new_entry.file_id,
1136
1146
                                               "New id is already present in target.")
1137
1147
            except AttributeError:
1233
1243
        :return: entry
1234
1244
        """
1235
1245
        if entry.file_id in self._byid:
1236
 
            raise errors.DuplicateFileId(entry.file_id,
1237
 
                                         self._byid[entry.file_id])
 
1246
            raise DuplicateFileId(entry.file_id, self._byid[entry.file_id])
1238
1247
        if entry.parent_id is None:
1239
1248
            self.root = entry
1240
1249
        else: