81
81
"""Create a repo fetcher.
83
83
:param find_ghosts: If True search the entire history for ghosts.
84
:param _write_group_acquired_callable: Don't use; this parameter only
85
exists to facilitate a hack done in InterPackRepo.fetch. We would
86
like to remove this parameter.
85
88
# result variables.
86
89
self.failed_revisions = []
248
251
child_pb.finished()
250
253
def _fetch_revision_texts(self, revs, pb):
254
# fetch signatures first and then the revision texts
251
255
# may need to be a InterRevisionStore call here.
252
256
to_sf = self.to_repository.signatures
253
257
from_sf = self.from_repository.signatures
255
259
to_sf.insert_record_stream(filter_absent(from_sf.get_record_stream(
256
260
[(rev_id,) for rev_id in revs],
257
261
self.to_repository._fetch_order,
259
# Bug #261339, some knit repositories accidentally had deltas in their
260
# revision stream, when you weren't ever supposed to have deltas.
261
# So we now *force* fulltext copying for signatures and revisions
262
not self.to_repository._fetch_uses_deltas)))
262
263
self._fetch_just_revision_texts(revs)
264
265
def _fetch_just_revision_texts(self, version_ids):
265
266
to_rf = self.to_repository.revisions
266
267
from_rf = self.from_repository.revisions
268
# If a revision has a delta, this is actually expanded inside the
269
# insert_record_stream code now, which is an alternate fix for
267
271
to_rf.insert_record_stream(from_rf.get_record_stream(
268
272
[(rev_id,) for rev_id in version_ids],
269
273
self.to_repository._fetch_order,
271
# Bug #261339, some knit repositories accidentally had deltas in their
272
# revision stream, when you weren't ever supposed to have deltas.
273
# So we now *force* fulltext copying for signatures and revisions
274
not self.to_repository._fetch_uses_deltas))
275
276
def _generate_root_texts(self, revs):
276
277
"""This will be called by __fetch between fetching weave texts and