~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/upgrade.py

  • Committer: Robert Collins
  • Date: 2005-10-16 08:13:23 UTC
  • mto: This revision was merged to the branch mainline in revision 1459.
  • Revision ID: robertc@lifelesslap.robertcollins.net-20051016081323-8393c2878dc4dc9e
convert all users of __getitem__ into TransportStores to use .get instead

Show diffs side-by-side

added added

removed removed

Lines of Context:
270
270
                 rev_id)
271
271
            self.absent_revisions.add(rev_id)
272
272
        else:
273
 
            rev_xml = self.branch.revision_store[rev_id].read()
 
273
            rev_xml = self.branch.revision_store.get(rev_id).read()
274
274
            rev = serializer_v4.read_revision_from_string(rev_xml)
275
275
            for parent_id in rev.parent_ids:
276
276
                self.known_revisions.add(parent_id)
280
280
 
281
281
    def _load_old_inventory(self, rev_id):
282
282
        assert rev_id not in self.converted_revs
283
 
        old_inv_xml = self.branch.inventory_store[rev_id].read()
 
283
        old_inv_xml = self.branch.inventory_store.get(rev_id).read()
284
284
        inv = serializer_v4.read_inventory_from_string(old_inv_xml)
285
285
        rev = self.revisions[rev_id]
286
286
        if rev.inventory_sha1:
375
375
                return
376
376
        parent_indexes = map(w.lookup, previous_revisions)
377
377
        if ie.has_text():
378
 
            file_lines = self.branch.text_store[ie.text_id].readlines()
 
378
            file_lines = self.branch.text_store.get(ie.text_id).readlines()
379
379
            assert sha_strings(file_lines) == ie.text_sha1
380
380
            assert sum(map(len, file_lines)) == ie.text_size
381
381
            w.add(rev_id, parent_indexes, file_lines, ie.text_sha1)