Merge lp:~spiv/bzr/stacked-2a-reconcile into lp:bzr

Proposed by Andrew Bennetts
Status: Work in progress
Proposed branch: lp:~spiv/bzr/stacked-2a-reconcile
Merge into: lp:bzr
Diff against target: 21 lines (+2/-3)
1 file modified
bzrlib/repofmt/groupcompress_repo.py (+2/-3)
To merge this branch: bzr merge lp:~spiv/bzr/stacked-2a-reconcile
Reviewer Review Type Date Requested Status
bzr-core Pending
Review via email: mp+32074@code.launchpad.net

Description of the change

See description of bug 615236; GCCHKPacker got fixed at some point to take parent inventories for stacking into account, but the GCCHKReconcilePacker didn't get a corresponding change. This patch makes them share the relevant code.

Probably this should have a test before merging, but I'd like to get feedback on whether my understanding of the code is correct, if anyone knows :)

To post a comment you must log in.
Revision history for this message
Robert Collins (lifeless) wrote :

Looks sane offhand.

Revision history for this message
Vincent Ladeuil (vila) wrote :

Considering Robert's comment as addressing your feedback query, I'll mark this as WIP waiting for your test :)

Unmerged revisions

5375. By Andrew Bennetts

Reuse GCCHKPacker's _copy_inventory_texts in GCCHKReconcilePacker, including missing_inventories logic.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'bzrlib/repofmt/groupcompress_repo.py'
--- bzrlib/repofmt/groupcompress_repo.py 2010-05-14 13:25:05 +0000
+++ bzrlib/repofmt/groupcompress_repo.py 2010-08-09 08:52:44 +0000
@@ -424,6 +424,7 @@
424 % (missing_inventories,))424 % (missing_inventories,))
425 self._copy_stream(source_vf, target_vf, inventory_keys,425 self._copy_stream(source_vf, target_vf, inventory_keys,
426 'inventories', self._get_filtered_inv_stream, 2)426 'inventories', self._get_filtered_inv_stream, 2)
427 return source_vf
427428
428 def _copy_chk_texts(self):429 def _copy_chk_texts(self):
429 source_vf, target_vf = self._build_vfs('chk', False, False)430 source_vf, target_vf = self._build_vfs('chk', False, False)
@@ -506,9 +507,7 @@
506 self._gather_text_refs = True507 self._gather_text_refs = True
507508
508 def _copy_inventory_texts(self):509 def _copy_inventory_texts(self):
509 source_vf, target_vf = self._build_vfs('inventory', True, True)510 source_vf = super(GCCHKReconcilePacker, self)._copy_inventory_texts()
510 self._copy_stream(source_vf, target_vf, self.revision_keys,
511 'inventories', self._get_filtered_inv_stream, 2)
512 if source_vf.keys() != self.revision_keys:511 if source_vf.keys() != self.revision_keys:
513 self._data_changed = True512 self._data_changed = True
514513