/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

Merge the bulg of the fix for 320119 and fix NEWS entrieS

Show diffs side-by-side

added added

removed removed

Lines of Context:
456
456
            stop_revision_id, stop_rule)
457
457
        # Make sure we don't return revisions that are not part of the
458
458
        # start_revision_id ancestry.
459
 
        filtered = self._filter_non_ancestors(filtered)
 
459
        filtered = self._filter_start_non_ancestors(filtered)
460
460
        if direction == 'reverse':
461
461
            return filtered
462
462
        if direction == 'forward':
499
499
                       node.end_of_merge)
500
500
                if rev_id == stop_revision_id:
501
501
                    return
 
502
        elif stop_rule == 'with-merges-without-common-ancestry':
 
503
            # We want to exclude all revisions that are already part of the
 
504
            # stop_revision_id ancestry.
 
505
            graph = self.repository.get_graph()
 
506
            for node in rev_iter:
 
507
                rev_id = node.key[-1]
 
508
                if graph.is_ancestor(rev_id, stop_revision_id):
 
509
                    continue
 
510
                yield (rev_id, node.merge_depth, node.revno,
 
511
                       node.end_of_merge)
502
512
        elif stop_rule == 'with-merges':
503
513
            stop_rev = self.repository.get_revision(stop_revision_id)
504
514
            if stop_rev.parent_ids:
527
537
        else:
528
538
            raise ValueError('invalid stop_rule %r' % stop_rule)
529
539
 
530
 
    def _filter_non_ancestors(self, rev_iter):
 
540
    def _filter_start_non_ancestors(self, rev_iter):
531
541
        # If we started from a dotted revno, we want to consider it as a tip
532
542
        # and don't want to yield revisions that are not part of its
533
543
        # ancestry. Given the order guaranteed by the merge sort, we will see