~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/log.py

  • Committer: Alexander Belchenko
  • Date: 2007-11-19 22:54:30 UTC
  • mfrom: (3006 +trunk)
  • mto: This revision was merged to the branch mainline in revision 3008.
  • Revision ID: bialix@ukr.net-20071119225430-x0ewosrsagis0yno
merge bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
57
57
    symbol_versioning,
58
58
    )
59
59
import bzrlib.errors as errors
60
 
from bzrlib.revisionspec import(
61
 
    RevisionInfo
 
60
from bzrlib.revision import (
 
61
    NULL_REVISION,
 
62
    )
 
63
from bzrlib.revisionspec import (
 
64
    RevisionInfo,
62
65
    )
63
66
from bzrlib.symbol_versioning import (
64
67
    deprecated_method,
229
232
    else:
230
233
        generate_merge_revisions = getattr(lf, 'supports_merge_revisions', 
231
234
                                           False)
 
235
    if ((not generate_merge_revisions)
 
236
        and ((start_rev_id and (start_rev_id not in rev_nos))
 
237
            or (end_rev_id and (end_rev_id not in rev_nos)))):
 
238
        from bzrlib.errors import BzrCommandError
 
239
        raise BzrCommandError('Selected log formatter only supports '
 
240
            'mainline revisions.')
232
241
    view_revs_iter = get_view_revisions(mainline_revs, rev_nos, branch,
233
242
                          direction, include_merges=generate_merge_revisions)
234
243
    view_revisions = _filter_revision_range(list(view_revs_iter),
356
365
            branch.check_real_revno(end_revision)
357
366
            end_revno = end_revision
358
367
 
 
368
    if ((start_rev_id == NULL_REVISION)
 
369
        or (end_rev_id == NULL_REVISION)):
 
370
        from bzrlib.errors import BzrCommandError
 
371
        raise BzrCommandError('Logging revision 0 is invalid.')
359
372
    if start_revno > end_revno:
360
373
        from bzrlib.errors import BzrCommandError
361
374
        raise BzrCommandError("Start revision must be older than "