/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 bzrlib/inventory.py

  • Committer: v.ladeuil+lp at free
  • Date: 2006-11-08 07:44:30 UTC
  • mfrom: (2123 +trunk)
  • mto: (2145.1.1 keepalive)
  • mto: This revision was merged to the branch mainline in revision 2146.
  • Revision ID: v.ladeuil+lp@free.fr-20061108074430-a9c08d4a475bd97f
Merge bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
1036
1036
        try:
1037
1037
            return self._byid[file_id]
1038
1038
        except KeyError:
1039
 
            if file_id is None:
1040
 
                raise BzrError("can't look up file_id None")
1041
 
            else:
1042
 
                raise BzrError("file_id {%s} not in inventory" % file_id)
 
1039
            # really we're passing an inventory, not a tree...
 
1040
            raise errors.NoSuchId(self, file_id)
1043
1041
 
1044
1042
    def get_file_kind(self, file_id):
1045
1043
        return self._byid[file_id].kind
1204
1202
            return None
1205
1203
        for f in name:
1206
1204
            try:
1207
 
                cie = parent.children[f]
 
1205
                children = getattr(parent, 'children', None)
 
1206
                if children is None:
 
1207
                    return None
 
1208
                cie = children[f]
1208
1209
                assert cie.name == f
1209
1210
                assert cie.parent_id == parent.file_id
1210
1211
                parent = cie