"exceptions.ValueError: get_parent_map(None) is not valid" in before:$invalid_dotted_revno

Bug #240346 reported by Michael Hudson-Doyle
2
Affects Status Importance Assigned to Milestone
Bazaar
Fix Released
Low
Unassigned

Bug Description

More specifically:

mwh@grond:~/canonical/repos/loggerhead/trunk$ bzr.dev revision-info -r before:11111111111111.111111111111111
bzr: ERROR: exceptions.ValueError: get_parent_map(None) is not valid

Traceback (most recent call last):
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/commands.py", line 846, in run_bzr_catch_errors
    return run_bzr(argv)
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/commands.py", line 797, in run_bzr
    ret = run(*run_argv)
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/commands.py", line 499, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/commands.py", line 807, in ignore_pipe
    result = func(*args, **kwargs)
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/builtins.py", line 287, in run
    revision_id = rev.as_revision_id(b)
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/revisionspec.py", line 245, in as_revision_id
    return self._as_revision_id(context_branch)
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/revisionspec.py", line 530, in _as_revision_id
    parent_map = context_repo.get_parent_map([base_revision_id])
  File "/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/repofmt/pack_repo.py", line 1925, in get_parent_map
    raise ValueError('get_parent_map(None) is not valid')
ValueError: get_parent_map(None) is not valid

bzr 1.6b3 on python 2.5.2 (linux2)
arguments: ['/home/mwh/canonical/repos/bzr/bzr.dev/bzr', 'revision-info', '-r', 'before:11111111111111.111111111111111']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'en_NZ.UTF-8'
plugins:
  bpm /home/mwh/.bazaar/plugins/bpm [unknown]
  bzrtools /usr/lib/python2.5/site-packages/bzrlib/plugins/bzrtools [1.5.0]
  gtk /home/mwh/.bazaar/plugins/gtk [0.95.0dev1]
  launchpad /home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/plugins/launchpad [unknown]
  lpreview /home/mwh/.bazaar/plugins/lpreview [unknown]
  pqm /home/mwh/.bazaar/plugins/pqm [1.4.0dev0]
  search /home/mwh/.bazaar/plugins/search [1.6.0dev0]
  svn /home/mwh/.bazaar/plugins/svn [0.4.11dev0]
*** Bazaar has encountered an internal error.
    Please report a bug at https://bugs.launchpad.net/bzr/+filebug
    including this traceback, and a description of what you
    were doing when the error occurred.

(this is loggerhead trunk, lp:loggerhead, but I hardly believe that matters)

This is probably not entirely unrelated:

mwh@grond:~/canonical/repos/loggerhead/trunk$ bzr.dev revision-info -r 11111111111111.111111111111111
/home/mwh/canonical/repos/bzr/bzr.dev/bzrlib/branch.py:512: DeprecationWarning: NULL_REVISION should be used for the null revision instead of None, as of bzr 0.90.
  if _mod_revision.is_null(revision_id):
   0 None

(the above is with bzr.dev 3495)

Tags: easy
Revision history for this message
James Westby (james-w) wrote :

Hi,

Thanks for your bug report, I can confirm this behaviour.

Thanks,

James

Changed in bzr:
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
John A Meinel (jameinel) wrote :

It doesn't matter the branch, it is the fact that 11111.11111 doesn't exist. The code is doing:

if len(revisions) != 1:
    return branch, None, None

I would have thought that we would actually want to be raising errors.InvalidRevisionSpec at this point.

Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

This seems to be fixed now:

mwh@grond:trunk+$ bzr revision-info -r before:11111111111111
bzr: ERROR: Requested revision: u'11111111111111' does not exist in branch: BzrBranch6('file:///home/mwh/canonical/repos/launchpad/trunk%2B/')

Changed in bzr:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.