~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/missing.py

Dirty merge of the mainline

Show diffs side-by-side

added added

removed removed

Lines of Context:
10
10
    for revno, rev_id in revisions:
11
11
        rev = revision_source.get_revision(rev_id)
12
12
        if verbose:
 
13
            remote_tree = revision_source.revision_tree(rev_id)
13
14
            parent_rev_id = rev.parent_ids[0]
14
15
            if last_rev_id == parent_rev_id:
15
16
                parent_tree = last_tree
43
44
                                                remote_rev_history_map)
44
45
                return local_extra, remote_extra
45
46
 
46
 
            local_ancestry = _get_ancestry(local_branch, progress, "local",
47
 
                                           2, local_rev_history)
48
 
            remote_ancestry = _get_ancestry(remote_branch, progress, "remote",
49
 
                                            3, remote_rev_history)
 
47
            local_ancestry = _get_ancestry(local_branch.repository, progress, 
 
48
                                           "local", 2, local_rev_history)
 
49
            remote_ancestry = _get_ancestry(remote_branch.repository, progress,
 
50
                                            "remote", 3, remote_rev_history)
50
51
            progress.update('pondering', 4, 5)
51
52
            extras = local_ancestry.symmetric_difference(remote_ancestry) 
52
53
            local_extra = extras.intersection(set(local_rev_history))
87
88
         for rev in rev_history])
88
89
    return rev_history, rev_history_map
89
90
 
90
 
def _get_ancestry(branch, progress, label, step, rev_history):
 
91
def _get_ancestry(repository, progress, label, step, rev_history):
91
92
    progress.update('%s ancestry' % label, step, 5)
92
93
    if len(rev_history) > 0:
93
 
        ancestry = set(branch.get_ancestry(rev_history[-1]))
 
94
        ancestry = set(repository.get_ancestry(rev_history[-1]))
94
95
    else:
95
96
        ancestry = set()
96
97
    return ancestry