~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/repository.py

Merge in the new add_inventory_by_delta and handle the new return values.

Show diffs side-by-side

added added

removed removed

Lines of Context:
685
685
            graph access, as well as for those that pun ancestry with delta
686
686
            compression.
687
687
 
688
 
        :returns: The validator(which is a sha1 digest, though what is sha'd is
689
 
            repository format specific) of the serialized inventory.
 
688
        :returns: (validator, new_inv)
 
689
            The validator(which is a sha1 digest, though what is sha'd is
 
690
            repository format specific) of the serialized inventory, and the
 
691
            resulting inventory.
690
692
        """
691
693
        if not self.is_in_write_group():
692
694
            raise AssertionError("%r not in write group" % (self,))
701
703
            basis_inv = basis_tree.inventory
702
704
            basis_inv.apply_delta(delta)
703
705
            basis_inv.revision_id = new_revision_id
704
 
            return self.add_inventory(new_revision_id, basis_inv, parents)
 
706
            return (self.add_inventory(new_revision_id, basis_inv, parents),
 
707
                    basis_inv)
705
708
        finally:
706
709
            basis_tree.unlock()
707
710