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

More coalescing tweaks, and knit feedback.

Show diffs side-by-side

added added

removed removed

Lines of Context:
67
67
import difflib
68
68
from difflib import SequenceMatcher
69
69
from gzip import GzipFile
 
70
from itertools import izip
70
71
import os
71
72
 
 
73
 
72
74
import bzrlib
73
75
import bzrlib.errors as errors
74
76
from bzrlib.errors import FileExists, NoSuchFile, KnitError, \
537
539
        count = 0
538
540
        total = len(version_id_records)
539
541
        try:
 
542
            pb.update('Walking content.', count, total)
540
543
            for version_id, data, sha_value in \
541
544
                self._data.read_records_iter(version_id_records):
542
545
                pb.update('Walking content.', count, total)
553
556
                        for origin, line in lines:
554
557
                            yield line
555
558
                count +=1
 
559
            pb.update('Walking content.', total, total)
 
560
            pb.finished()
556
561
        except:
557
562
            pb.update('Walking content.', total, total)
558
563
            pb.finished()
972
977
        response = self._transport.readv(self._filename,
973
978
            [(pos, size) for version_id, pos, size in records])
974
979
 
975
 
        for (record_id, pos, size), (pos, data) in zip(records, response):
 
980
        for (record_id, pos, size), (pos, data) in izip(iter(records), response):
976
981
            content, digest = self._parse_record(record_id, data)
977
982
            yield record_id, content, digest
978
983