~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/workingtree_4.py

A few more bug fixes.

Handle when a location changes file_id. We were looking up the path
in the active tree, we need to look it up in the basis_tree.
Add a direct test for the 'switch' case, which is when setting
a parent_tree to something new, and the basis_tree is no longer
in the available repository.
Add a couple more direct successful delta checks. (most of the
test_inv tests were just about failing with bad deltas.)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1158
1158
            try:
1159
1159
                basis_tree = self.branch.repository.revision_tree(basis_id)
1160
1160
            except errors.NoSuchRevision:
1161
 
                pass # Fallback to set_parent_trees
 
1161
                # Fall back to the set_parent_trees(), since we can't use
 
1162
                # _make_delta if we can't get the RevisionTree
 
1163
                pass
1162
1164
            else:
1163
1165
                delta = rev_tree.inventory._make_delta(basis_tree.inventory)
1164
1166
                dirstate.update_basis_by_delta(delta, rev_id)