/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/memorytree.py

  • Committer: Jelmer Vernooij
  • Date: 2018-03-24 13:49:31 UTC
  • mto: This revision was merged to the branch mainline in revision 6915.
  • Revision ID: jelmer@jelmer.uk-20180324134931-zi72oabn3r4onuk7
Fail early in MemoryTree.unversion.

Show diffs side-by-side

added added

removed removed

Lines of Context:
270
270
            # is not relevant to memory tree. Until that is done in unlock by
271
271
            # working tree, we cannot share the implementation.
272
272
            if file_ids is None:
273
 
                file_ids = {self.path2id(path) for path in paths}
 
273
                file_ids = set()
 
274
                for path in paths:
 
275
                    file_id = self.path2id(path)
 
276
                    if file_id is None:
 
277
                        raise errors.NoSuchFile(path)
 
278
                    file_ids.add(file_id)
274
279
            for file_id in file_ids:
275
280
                if self._inventory.has_id(file_id):
276
281
                    self._inventory.remove_recursive_id(file_id)