<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Am 14.06.2012 09:18, schrieb Marius Gedminas:
<blockquote cite="mid:20120614071826.GA27643@platonas" type="cite">
<pre wrap="">On Wed, Jun 13, 2012 at 10:58:01PM +0200, Ralf Hauenschild wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Am 13.06.2012 19:36, schrieb Alexandre Garel:
</pre>
<blockquote type="cite">
<pre wrap="">Le 13/06/2012 18:57, Ralf Hauenschild a écrit :
</pre>
<blockquote type="cite">
<pre wrap="">Hello guys,
i've been desperately trying to install ZODB3 via the following ways:
- easy_install ZODB3
- installation of Zope2
- manual installation of ZODB3, preceeded by installation of the
requested packages from pypi
I'm using Ubuntu and Python 2.6.
Whe trying to import ZODB, I'm still getting the following error:
python
Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
</pre>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">
<pre wrap="">import ZODB
</pre>
</blockquote>
</blockquote>
</blockquote>
<pre wrap="">Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/__init__.py",
line 28, in <module>
from DB import DB, connection
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/DB.py",
line 28, in <module>
from ZODB.Connection import Connection
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/Connection.py",
line 33, in <module>
from ZODB.blob import Blob, rename_or_copy_blob,
remove_committed_dir
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/blob.py",
line 35, in <module>
from ZODB.POSException import POSKeyError
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/POSException.py",
line 71, in <module>
class ConflictError(POSError,
transaction.interfaces.TransientError):
AttributeError: 'module' object has no attribute 'TransientError'
</pre>
</blockquote>
</blockquote>
</blockquote>
<pre wrap="">
You need a newer version of the 'transaction' package. Unfortunately
the changelog at <a class="moz-txt-link-freetext" href="http://pypi.python.org/pypi/transaction">http://pypi.python.org/pypi/transaction</a> doesn't say
which version added TransientError, but why not get the latest one?
</pre>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">
<pre wrap="">Can anybody help me, please?
</pre>
</blockquote>
<pre wrap="">
The problem may be with a system wide installed version of transaction.
I would say, try in a virtualenv with no site packages :
$ virtualenv -p /usr/bin/python2.6 --no-site-packages myproject
$ cd myproject
$ . bin/activate
$ pip install ZODB3
Hope this helps,
</pre>
</blockquote>
<pre wrap="">
Unfortunately, the error remains :(
</pre>
</blockquote>
<pre wrap="">
Hm.. What version of 'transaction' do you get?
</pre>
<blockquote type="cite">
<pre wrap="">Thank you, Alex, anyway.
The suggestest installation went without any complications:
......
......
...
External_Tools/zdaemon-3.0.1/myproject/bin
Installing fsdump script to /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/bin
Installing fsrefs script to /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/bin
Installing repozo script to /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/bin
Installing fsoids script to /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/bin
Running setup.py install for zope.event
Skipping installation of /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/lib/python2.6/site-packages/zope/__init__.py
(namespace package)
Installing /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/lib/python2.6/site-packages/zope.event-4.0.0-py2.6-nspkg.pth
Running setup.py install for zope.interface
building 'zope.interface._zope_interface_coptimizations' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall
-Wstrict-prototypes -fPIC -I/usr/include/python2.6 -c
src/zope/interface/_zope_interface_coptimizations.c -o build/temp.linux-x86_64-2.6/src/zope/interface/_zope_interface_coptimizations.o
gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions build/temp.linux-x86_64-2.6/src/zope/interface/_zope_interface_coptimizations.o
-o build/lib.linux-x86_64-2.6/zope/interface/_zope_interface_coptimizations.so
Skipping installation of /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/lib/python2.6/site-packages/zope/__init__.py
(namespace package)
Installing /media/daten/tyan/blast-tyan16x/External_Tools/zdaemon-3.0.1/myproject/lib/python2.6/site-packages/zope.interface-4.0.1-py2.6-nspkg.pth
Successfully installed transaction zc.lockfile ZConfig zdaemon ZODB3
zope.event zope.interface
</pre>
</blockquote>
<pre wrap="">
Hm, you should've gotten the latest one.
</pre>
<blockquote type="cite">
<pre wrap="">I still get:
python
Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
</pre>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">
<pre wrap="">import ZODB
</pre>
</blockquote>
</blockquote>
</blockquote>
<pre wrap="">Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/__init__.py",
</pre>
</blockquote>
<pre wrap="">
You're clearly not using an isolated virtualenv if you get packages from
/usr/loca/lib/python2.6/dist-packages!
Do you have PYTHONPATH set in your environment?
</pre>
<blockquote type="cite">
<pre wrap="">line 28, in <module>
from DB import DB, connection
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/DB.py",
line 28, in <module>
from ZODB.Connection import Connection
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/Connection.py",
line 33, in <module>
from ZODB.blob import Blob, rename_or_copy_blob, remove_committed_dir
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/blob.py",
line 35, in <module>
from ZODB.POSException import POSKeyError
File "/usr/local/lib/python2.6/dist-packages/ZODB3-3.10.5-py2.6-linux-x86_64.egg/ZODB/POSException.py",
line 71, in <module>
class ConflictError(POSError, transaction.interfaces.TransientError):
AttributeError: 'module' object has no attribute 'TransientError'
</pre>
<blockquote type="cite">
<blockquote type="cite">
<blockquote type="cite">
<pre wrap="">
</pre>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
<pre wrap="">
Can you do
>>> import transaction
>>> transaction.__file__
?
Marius Gedminas
</pre>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
For more information about ZODB, see <a class="moz-txt-link-freetext" href="http://zodb.org/">http://zodb.org/</a>
ZODB-Dev mailing list - <a class="moz-txt-link-abbreviated" href="mailto:ZODB-Dev@zope.org">ZODB-Dev@zope.org</a>
<a class="moz-txt-link-freetext" href="https://mail.zope.org/mailman/listinfo/zodb-dev">https://mail.zope.org/mailman/listinfo/zodb-dev</a>
</pre>
</blockquote>
<br>
<br>
The <br>
<pre wrap=""> >>> import transaction
>>> transaction.__file__</pre>
resulted in (@ virtualev and globalenv):<br>
<br>
<br>
Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41) <br>
[GCC 4.4.3] on linux2<br>
Type "help", "copyright", "credits" or "license" for more
information.<br>
>>> import transaction<br>
>>> transaction.__file__<br>
'/usr/lib/python2.6/dist-packages/transaction/__init__.pyc'<br>
>>> <br>
<br>
The following things I did in the virtualenv, like you guys had
proposed:<br>
I just tried to do "python setup.py test", which failed with the
same import error as described above.<br>
I therefore just reinstalled ZODB by "python setup.py install", then
launched "python setup.py test" again.<br>
The second time, the test has been running and printing for several
minutes:<br>
<br>
It ended with:<br>
..........<br>
.....<br>
Doctest: ZODB.tests.testblob.savepoint_isolation ... ok<br>
Doctest: ZODB.tests.testblob.secure_blob_directory ... ok<br>
testRedo (ZODB.tests.testblob.ClientStorageSharedBlobsBlobUndoTests)
... ok<br>
testRedoOfCreation
(ZODB.tests.testblob.ClientStorageSharedBlobsBlobUndoTests) ... ok<br>
testUndo (ZODB.tests.testblob.ClientStorageSharedBlobsBlobUndoTests)
... ok<br>
testUndoAfterConsumption
(ZODB.tests.testblob.ClientStorageSharedBlobsBlobUndoTests) ... ok<br>
testUndoWithoutPreviousVersion
(ZODB.tests.testblob.ClientStorageSharedBlobsBlobUndoTests) ... ok<br>
<br>
----------------------------------------------------------------------<br>
Ran 701 tests in 988.767s<br>
<br>
OK<br>
<br>
All this in the virtualenv!!!<br>
<br>
Then, I was able to import ZODB for the first time:<br>
<br>
(<a class="moz-txt-link-abbreviated" href="mailto:myproject)tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$">myproject)tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$</a>
python<br>
Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41) <br>
[GCC 4.4.3] on linux2<br>
Type "help", "copyright", "credits" or "license" for more
information.<br>
>>> import ZODB<br>
>>> quit()<br>
(<a class="moz-txt-link-abbreviated" href="mailto:myproject)tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$">myproject)tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$</a>
<br>
<br>
<br>
<br>
<br>
But, when I switch to globalenv (real system path) again, I still
get the import errors:<br>
<br>
<a class="moz-txt-link-abbreviated" href="mailto:tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$">tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$</a>
sudo python setup.py test<br>
running test<br>
running egg_info<br>
writing requirements to src/ZODB3.egg-info/requires.txt<br>
writing src/ZODB3.egg-info/PKG-INFO<br>
writing top-level names to src/ZODB3.egg-info/top_level.txt<br>
writing dependency_links to src/ZODB3.egg-info/dependency_links.txt<br>
writing entry points to src/ZODB3.egg-info/entry_points.txt<br>
reading manifest file 'src/ZODB3.egg-info/SOURCES.txt'<br>
writing manifest file 'src/ZODB3.egg-info/SOURCES.txt'<br>
running build_ext<br>
copying build/lib.linux-x86_64-2.6/BTrees/_OOBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_IOBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_OIBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_IIBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_IFBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_fsBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_LOBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_OLBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_LLBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/BTrees/_LFBTree.so ->
src/BTrees<br>
copying build/lib.linux-x86_64-2.6/persistent/cPersistence.so ->
src/persistent<br>
copying build/lib.linux-x86_64-2.6/persistent/cPickleCache.so ->
src/persistent<br>
copying build/lib.linux-x86_64-2.6/persistent/TimeStamp.so ->
src/persistent<br>
Traceback (most recent call last):<br>
File "setup.py", line 216, in <module><br>
include_package_data = True,<br>
File "/usr/lib/python2.6/distutils/core.py", line 152, in setup<br>
dist.run_commands()<br>
File "/usr/lib/python2.6/distutils/dist.py", line 975, in
run_commands<br>
self.run_command(cmd)<br>
File "/usr/lib/python2.6/distutils/dist.py", line 995, in
run_command<br>
cmd_obj.run()<br>
File
"/usr/lib/python2.6/dist-packages/setuptools/command/test.py", line
137, in run<br>
self.with_project_on_sys_path(self.run_tests)<br>
File
"/usr/lib/python2.6/dist-packages/setuptools/command/test.py", line
117, in with_project_on_sys_path<br>
func()<br>
File
"/usr/lib/python2.6/dist-packages/setuptools/command/test.py", line
146, in run_tests<br>
testLoader = loader_class()<br>
File "/usr/lib/python2.6/unittest.py", line 816, in __init__<br>
self.parseArgs(argv)<br>
File "/usr/lib/python2.6/unittest.py", line 843, in parseArgs<br>
self.createTests()<br>
File "/usr/lib/python2.6/unittest.py", line 849, in createTests<br>
self.module)<br>
File "/usr/lib/python2.6/unittest.py", line 613, in
loadTestsFromNames<br>
suites = [self.loadTestsFromName(name, module) for name in
names]<br>
File "/usr/lib/python2.6/unittest.py", line 598, in
loadTestsFromName<br>
test = obj()<br>
File "setup.py", line 134, in alltests<br>
import ZEO.ClientStorage<br>
File
"/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5/src/ZEO/ClientStorage.py",
line 24, in <module><br>
from ZEO.cache import ClientCache<br>
File
"/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5/src/ZEO/cache.py",
line 35, in <module><br>
import ZODB.fsIndex<br>
File
"/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5/src/ZODB/__init__.py",
line 28, in <module><br>
from DB import DB, connection<br>
File
"/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5/src/ZODB/DB.py",
line 28, in <module><br>
from ZODB.Connection import Connection<br>
File
"/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5/src/ZODB/Connection.py",
line 33, in <module><br>
from ZODB.blob import Blob, rename_or_copy_blob,
remove_committed_dir<br>
File
"/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5/src/ZODB/blob.py",
line 34, in <module><br>
from ZODB import utils<br>
ImportError: cannot import name utils<br>
<a class="moz-txt-link-abbreviated" href="mailto:tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$">tyan@tyan-desktop:/media/daten/tyan/blast-tyan16x/External_Tools/ZODB3-3.10.5$</a>
<br>
<br>
:(<br>
<br>
Any further ideas?<br>
Python path is set in the global environment. In the virtualenv, it
was not set, but everything worked there anyway.<br>
<br>
<br>
Best regards,<br>
Ralf<br>
<br>
<br>
<br>
</body>
</html>