~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/upgrade.py

  • Committer: Aaron Bentley
  • Date: 2005-12-25 00:38:48 UTC
  • mto: (1185.67.11 bzr.revision-storage)
  • mto: This revision was merged to the branch mainline in revision 1550.
  • Revision ID: aaron.bentley@utoronto.ca-20051225003848-111ac71170cb2605
Renamed Branch.storage to Branch.repository

Show diffs side-by-side

added added

removed removed

Lines of Context:
242
242
        self.pb.update('loading revision',
243
243
                       len(self.revisions),
244
244
                       len(self.known_revisions))
245
 
        if not self.branch.storage.revision_store.has_id(rev_id):
 
245
        if not self.branch.repository.revision_store.has_id(rev_id):
246
246
            self.pb.clear()
247
247
            note('revision {%s} not present in branch; '
248
248
                 'will be converted as a ghost',
249
249
                 rev_id)
250
250
            self.absent_revisions.add(rev_id)
251
251
        else:
252
 
            rev_xml = self.branch.storage.revision_store.get(rev_id).read()
 
252
            rev_xml = self.branch.repository.revision_store.get(rev_id).read()
253
253
            rev = serializer_v4.read_revision_from_string(rev_xml)
254
254
            for parent_id in rev.parent_ids:
255
255
                self.known_revisions.add(parent_id)
259
259
 
260
260
    def _load_old_inventory(self, rev_id):
261
261
        assert rev_id not in self.converted_revs
262
 
        old_inv_xml = self.branch.storage.inventory_store.get(rev_id).read()
 
262
        old_inv_xml = self.branch.repository.inventory_store.get(rev_id).read()
263
263
        inv = serializer_v4.read_inventory_from_string(old_inv_xml)
264
264
        rev = self.revisions[rev_id]
265
265
        if rev.inventory_sha1:
354
354
                return
355
355
        parent_indexes = map(w.lookup, previous_revisions)
356
356
        if ie.has_text():
357
 
            text = self.branch.storage.text_store.get(ie.text_id)
 
357
            text = self.branch.repository.text_store.get(ie.text_id)
358
358
            file_lines = text.readlines()
359
359
            assert sha_strings(file_lines) == ie.text_sha1
360
360
            assert sum(map(len, file_lines)) == ie.text_size