bzr internal error: AttributeError: 'module' object has no attribute 'builtins'
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| Bazaar |
Critical
|
Unassigned | ||
| 1.16 |
Undecided
|
Unassigned |
Bug Description
I get this error from running bzr in any way, except I can't find the flag that turns off plugin loading because it's not listed in the manpage and bzr --help does this too, so I can't try that...
% bzr
bzr: ERROR: exceptions.
Traceback (most recent call last):
File "/usr/lib/
return the_callable(*args, **kwargs)
File "/usr/lib/
from bzrlib.builtins import cmd_help
File "/usr/lib/
from bzrlib.foreign import cmd_dpush
File "/usr/lib/
from bzrlib.branch import (
File "/usr/lib/
__format7 = BzrBranchFormat7()
File "/usr/lib/
RepositoryF
File "/usr/lib/
obj = _replace()
File "/usr/lib/
obj = factory(self, scope, name)
File "/usr/lib/
module = __import_
File "/usr/lib/
from bzrlib.btree_index import (
File "/usr/lib/
import bisect
File "/home/
register_
File "/usr/lib/
return plugin_
File "/usr/lib/
previous = _builtin_
File "/usr/lib/
builtins = bzrlib.
AttributeError: 'module' object has no attribute 'builtins'
bzr 1.16.1 on python 2.5.4 (linux2)
arguments: ['/usr/bin/bzr']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'en_US.UTF-8'
plugins:
*** Bazaar has encountered an internal error.
Please report a bug at https:/
including this traceback, and a description of what you
were doing when the error occurred.
Robert Collins (lifeless) wrote : | #1 |
affects: | bzr → bzr-bisect |
Changed in bzr-bisect: | |
importance: | Undecided → Critical |
status: | New → Triaged |
Robert Collins (lifeless) wrote : | #2 |
Actually, its something else, bzrlib.builtins is just not loaded by the time register-command is being called. Putting back to bzr and fixing.
affects: | bzr-bisect → bzr |
Robert Collins (lifeless) wrote : | #3 |
This is fixed in bzr.dev already. I'm not sure why its showing up in 1.16. Looking into that now.
Changed in bzr: | |
status: | Triaged → Fix Released |
Robert Collins (lifeless) wrote : | #4 |
Sam, can you check the file
/usr/lib/
my 1.16 copy has
def _builtin_
import bzrlib.builtins
r = {}
builtins = bzrlib.
...
If yours has that, I don't see how it can be failing!
Perhap change it as follows:
def _builtin_
import bzrlib.builtins
import pdb;pdb.set_trace()
r = {}
and poke around in the debugger.
Robert Collins (lifeless) wrote : | #5 |
"" was in the PYTHONPATH, and bzr was being run from a directory with the 'bisect' plugin in it, leading to a circular import.
Changed in bzr: | |
status: | Fix Released → Invalid |
Doesn't import needed module.
So, bzr-bisect is using bzrlib.builtins, but doesn't import it itself :). The fix should be quite easy.
As a workaround, bzr --no-plugins ... - this will disable plugin loading.