Merge lp:~andrewsomething/bzr-grep/bzr2.6compat into lp:bzr-grep

Proposed by Andrew Starr-Bochicchio
Status: Needs review
Proposed branch: lp:~andrewsomething/bzr-grep/bzr2.6compat
Merge into: lp:bzr-grep
Diff against target: 15 lines (+4/-1)
1 file modified
grep.py (+4/-1)
To merge this branch: bzr merge lp:~andrewsomething/bzr-grep/bzr2.6compat
Reviewer Review Type Date Requested Status
Bazaar Developers Pending
Review via email: mp+126596@code.launchpad.net

Description of the change

Update to use 'graph.iter_lefthand_ancestry' instead of
'repo.iter_reverse_revision_history' making compatible with bzr 2.6

To post a comment you must log in.
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Note that bzr-grep has been merged into bzr core in newer versions of bzr.

Unmerged revisions

148. By Andrew Starr-Bochicchio

Make compatible with bzr 2.6

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'grep.py'
--- grep.py 2011-12-20 15:39:20 +0000
+++ grep.py 2012-09-27 03:50:24 +0000
@@ -67,7 +67,10 @@
67def _linear_view_revisions(branch, start_rev_id, end_rev_id):67def _linear_view_revisions(branch, start_rev_id, end_rev_id):
68 # requires that start is older than end68 # requires that start is older than end
69 repo = branch.repository69 repo = branch.repository
70 for revision_id in repo.iter_reverse_revision_history(end_rev_id):70 graph = repo.get_graph()
71 rev_sequence = graph.iter_lefthand_ancestry(end_rev_id,
72 (_mod_revision.NULL_REVISION,))
73 for revision_id in rev_sequence:
71 revno = branch.revision_id_to_dotted_revno(revision_id)74 revno = branch.revision_id_to_dotted_revno(revision_id)
72 revno_str = '.'.join(str(n) for n in revno)75 revno_str = '.'.join(str(n) for n in revno)
73 if revision_id == start_rev_id:76 if revision_id == start_rev_id:

Subscribers

People subscribed via source and target branches