[ZODB-Dev] Mysterious traceback ...
Stephen Waterbury
golux at comcast.net
Sat Jan 8 02:24:03 EST 2005
Tim Peters wrote:
> [Stephen Waterbury]
>
>>I just installed ZODB 3.3 (from ZODB3-3.3.tgz) on my machine (Debian
>>Sarge, Linux bigboote 2.6.8-1-686 #1 Thu Nov 25 04:34:30 UTC 2004 i686
>>GNU/Linux), and when I try to import ZODB I get:
>>
>>Python 2.3.4 (#2, Dec 3 2004, 13:53:17)
>>[GCC 3.3.5 (Debian 1:3.3.5-2)] on linux2
>>Type "help", "copyright", "credits" or "license" for more information.
>>
>>>>>import ZODB
>
> ...
>
>> warn("""Couldn't import the ExtensionClass-based base class
>>Traceback (most recent call last):
>> File "<stdin>", line 1, in ?
>> File "/usr/lib/python2.3/site-packages/ZODB/__init__.py", line 46, in ?
>> from DB import DB
>> File "/usr/lib/python2.3/site-packages/ZODB/DB.py", line 25, in ?
>> from ZODB.Connection import Connection
>> File "/usr/lib/python2.3/site-packages/ZODB/Connection.py", line 36, in
>
> ?
>
>> from ZODB.utils import oid_repr, z64, positive_id
>>ImportError: cannot import name positive_id
>>
>
>>help help!
>
> Nobody else has reported this, so the problem must lie in something you
> haven't told us. For example, *exactly* what did you that got summarized by
> "I just installed ZODB 3.3". For example, did you have an older version of
> ZODB installed in the same place?
Not that I could detect, unless Debian installs a ZODB package
that has a name that does not involve the string "ZODB" in any
combination of cases, because that's what I checked for before
I installed ZODB using 'python setup.py install' on the version
cited.
BTW, how come there isn't a Debian ZODB package that I can find
by this method:
$ wajig search zodb
zope-btreefolder2 - Zope folder that can efficiently contain many objects
zope-extfile - Stores large files outside Zope database
zope-exuserfolder - XUF -- user authentication, properties and sessions
zope-testcase - unit testing framework and test case for Zope
zope-zpatterns - Database Independence and Framework Integration for Zope
None of these look like they should contain ZODB either. Do they?
> If you simply look inside ZODB3-3.3.tgz, you'll quickly see that utils.py
> does indeed define a positive_id() function, so whatever it is that you did,
> you're not actually importing the ZODB.utils from the tarball.
Okay, I'll take your word for it (I just solved my problem by
downloading 3.1.5 and I don't feel like downloading 3.3
again just to look for something that you know is there).
BTW, what should I do if I'm installing most Python packages
using apt-get and then I come to ZODB which doesn't appear to
have been installed and then I install it and get this error?
Should I infer that I've got another version installed, and if so
how do I determine that and how do I get rid of it? (Sorry,
but I do get pissed off about all the pollution of site-packages
that ZODB traditionally does.) What's the recommended way of
clearing out a previously installed version that probably was
installed from a Debian package but I don't know which one, and
why the heck is it so hard to determine which one if indeed it
was installed in a Debian package (which didn't have "ZODB"
in its name in any form)? But I do also appreciate your help,
Tim. Thanks! :)
Cheers,
Steve
More information about the ZODB-Dev
mailing list