~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/fetch.py

  • Committer: John Arbash Meinel
  • Date: 2009-01-26 20:57:56 UTC
  • mto: This revision was merged to the branch mainline in revision 3964.
  • Revision ID: john@arbash-meinel.com-20090126205756-wh552ozttirfo2m9
There is no need to create a progress bar that we don't even use.

Show diffs side-by-side

added added

removed removed

Lines of Context:
232
232
    def _fetch_inventory_weave(self, revs, pb):
233
233
        pb.update("fetch inventory", 0, 2)
234
234
        to_weave = self.to_repository.inventories
235
 
        child_pb = bzrlib.ui.ui_factory.nested_progress_bar()
236
 
        try:
237
 
            # just merge, this is optimisable and its means we don't
238
 
            # copy unreferenced data such as not-needed inventories.
239
 
            pb.update("fetch inventory", 1, 3)
240
 
            from_weave = self.from_repository.inventories
241
 
            pb.update("fetch inventory", 2, 3)
242
 
            # we fetch only the referenced inventories because we do not
243
 
            # know for unselected inventories whether all their required
244
 
            # texts are present in the other repository - it could be
245
 
            # corrupt.
246
 
            to_weave.insert_record_stream(from_weave.get_record_stream(
247
 
                [(rev_id,) for rev_id in revs],
248
 
                self.to_repository._fetch_order,
249
 
                not self.to_repository._fetch_uses_deltas))
250
 
        finally:
251
 
            child_pb.finished()
 
235
        # just merge, this is optimisable and its means we don't
 
236
        # copy unreferenced data such as not-needed inventories.
 
237
        pb.update("fetch inventory", 1, 3)
 
238
        from_weave = self.from_repository.inventories
 
239
        pb.update("fetch inventory", 2, 3)
 
240
        # we fetch only the referenced inventories because we do not
 
241
        # know for unselected inventories whether all their required
 
242
        # texts are present in the other repository - it could be
 
243
        # corrupt.
 
244
        to_weave.insert_record_stream(from_weave.get_record_stream(
 
245
            [(rev_id,) for rev_id in revs],
 
246
            self.to_repository._fetch_order,
 
247
            not self.to_repository._fetch_uses_deltas))
252
248
 
253
249
    def _fetch_revision_texts(self, revs, pb):
254
250
        # fetch signatures first and then the revision texts