~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/log.py

  • Committer: Martin Pool
  • Date: 2005-08-30 03:10:32 UTC
  • Revision ID: mbp@sourcefrog.net-20050830031032-92ae5f0abb866ab8
- remove dead code and remove some small errors (pychecker)

Show diffs side-by-side

added added

removed removed

Lines of Context:
53
53
from bzrlib.tree import EmptyTree
54
54
from bzrlib.delta import compare_trees
55
55
from bzrlib.trace import mutter
 
56
from bzrlib.errors import InvalidRevisionNumber
56
57
 
57
58
 
58
59
def find_touching_revisions(branch, file_id):
161
162
    
162
163
    if start_revision is None:
163
164
        start_revision = 1
164
 
    else:
165
 
        branch.check_real_revno(start_revision)
 
165
    elif start_revision < 1 or start_revision >= len(which_revs):
 
166
        raise InvalidRevisionNumber(start_revision)
166
167
    
167
168
    if end_revision is None:
168
169
        end_revision = len(which_revs)
169
 
    else:
170
 
        branch.check_real_revno(end_revision)
 
170
    elif end_revision < 1 or end_revision >= len(which_revs):
 
171
        raise InvalidRevisionNumber(end_revision)
171
172
 
172
173
    # list indexes are 0-based; revisions are 1-based
173
174
    cut_revs = which_revs[(start_revision-1):(end_revision)]