[TIP] Dependencies installation order with Tox

holger krekel holger at merlinux.eu
Mon Jun 20 00:28:13 PDT 2011


Hi Aaron,

if you simply do:

    virtualenv --distribute --no-site-packages -p /sw/bin/python2.5 py25
    py25/bin/pip install numpy scipy

does it work?  If so, can you remove .tox (to remove the download cache)
and re-invoke it?

best,
holger

On Sun, Jun 19, 2011 at 19:26 -0600, Aaron Meurer wrote:
> Hi again.
> 
> I'm having another problem with dependencies with tox.  I'm trying to
> test using the dependencies numpy and scipy, but they do not install
> properly.  From what I can tell, scipy requires numpy, but it attempts
> to install scipy first, and so the whole thing fails.  This happens
> even though I have numpy listed first in the deps list.
> 
> I have attached a sample tox.ini file and output of the command tox -c
> tox.ini.test -v -r to demonstrate.  Note the basepython is just to
> ensure it uses fink's Python on my machine, which has numpy and scipy
> installed. I have both Python 2.5 and 2.7 just to see if it would
> work, but it appears that the behavior in both is the same.
> 
> Aaron Meurer

> [TOX] emptying /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/log
> [TOX] using tox.ini: /Users/aaronmeurer/Documents/python/sympy/sympy/tox.ini.test
> [TOX] using tox-0.9 from /Library/Python/2.6/site-packages/tox-0.9-py2.6.egg/tox/__init__.pyc
> ______________________________________________________________________________________________ [tox sdist] _______________________________________________________________________________________________
> [TOX] ***creating sdist package
> [TOX] emptying /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/dist
> [TOX] /Users/aaronmeurer/Documents/python/sympy/sympy$ /usr/bin/python setup.py sdist --formats=zip --dist-dir .tox/dist >.tox/log/0.log
> [TOX] ***copying new sdistfile to '/Users/aaronmeurer/.tox/distshare/sympy-0.7.0.rc2.zip'
> ___________________________________________________________________________________________ [tox testenv:py25] ___________________________________________________________________________________________
> [TOX] ***recreating virtualenv py25 (configchange/incomplete install detected)
> [TOX] emptying /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25
> [TOX] /Users/aaronmeurer/Documents/python/sympy/sympy/.tox$ virtualenv --distribute --no-site-packages -p /sw/bin/python2.5 py25 >py25/log/0.log
> [TOX] ***installing dependencies: numpy, scipy
> [TOX] /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/log$ ../bin/pip install --download-cache=/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/_download numpy scipy >1.log
> [TOX] ERROR: invocation failed, logfile: /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/log/1.log
> [TOX] ERROR: /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/log$ ../bin/pip install --download-cache=/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/_download numpy scipy >1.log
> Downloading/unpacking scipy
>   Using download cache from /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/_download/http%3A%2F%2Fpypi.python.org%2Fpackages%2Fsource%2Fs%2Fscipy%2Fscipy-0.9.0.zip
>   Running setup.py egg_info for package scipy
>     Traceback (most recent call last):
>       File "<string>", line 14, in <module>
>       File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/build/scipy/setup.py", line 181, in <module>
>         setup_package()
>       File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/build/scipy/setup.py", line 131, in setup_package
>         from numpy.distutils.core import setup
>     ImportError: No module named numpy.distutils.core
>     Complete output from command python setup.py egg_info:
>     Traceback (most recent call last):
> 
>   File "<string>", line 14, in <module>
> 
>   File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/build/scipy/setup.py", line 181, in <module>
> 
>     setup_package()
> 
>   File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py25/build/scipy/setup.py", line 131, in setup_package
> 
>     from numpy.distutils.core import setup
> 
> ImportError: No module named numpy.distutils.core
> 
> ----------------------------------------
> Command python setup.py egg_info failed with error code 1
> Storing complete log in /Users/aaronmeurer/.pip/pip.log
> 
> [TOX] ERROR: could not install deps [numpy, scipy]
> ___________________________________________________________________________________________ [tox testenv:py27] ___________________________________________________________________________________________
> [TOX] ***recreating virtualenv py27 (configchange/incomplete install detected)
> [TOX] emptying /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27
> [TOX] /Users/aaronmeurer/Documents/python/sympy/sympy/.tox$ virtualenv --distribute --no-site-packages -p /sw/bin/python2.7 py27 >py27/log/0.log
> [TOX] ***installing dependencies: numpy, scipy
> [TOX] /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/log$ ../bin/pip install --download-cache=/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/_download numpy scipy >1.log
> [TOX] ERROR: invocation failed, logfile: /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/log/1.log
> [TOX] ERROR: /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/log$ ../bin/pip install --download-cache=/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/_download numpy scipy >1.log
> Downloading/unpacking scipy
>   Using download cache from /Users/aaronmeurer/Documents/python/sympy/sympy/.tox/_download/http%3A%2F%2Fpypi.python.org%2Fpackages%2Fsource%2Fs%2Fscipy%2Fscipy-0.9.0.zip
>   Running setup.py egg_info for package scipy
>     Traceback (most recent call last):
>       File "<string>", line 14, in <module>
>       File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/build/scipy/setup.py", line 181, in <module>
>         setup_package()
>       File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/build/scipy/setup.py", line 131, in setup_package
>         from numpy.distutils.core import setup
>     ImportError: No module named numpy.distutils.core
>     Complete output from command python setup.py egg_info:
>     Traceback (most recent call last):
> 
>   File "<string>", line 14, in <module>
> 
>   File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/build/scipy/setup.py", line 181, in <module>
> 
>     setup_package()
> 
>   File "/Users/aaronmeurer/Documents/python/sympy/sympy/.tox/py27/build/scipy/setup.py", line 131, in setup_package
> 
>     from numpy.distutils.core import setup
> 
> ImportError: No module named numpy.distutils.core
> 
> ----------------------------------------
> Command python setup.py egg_info failed with error code 1
> Storing complete log in /Users/aaronmeurer/.pip/pip.log
> 
> [TOX] ERROR: could not install deps [numpy, scipy]
> _____________________________________________________________________________________________ [tox summary] ______________________________________________________________________________________________
> [TOX] ERROR: py25: could not install deps [numpy, scipy]
> [TOX] ERROR: py27: could not install deps [numpy, scipy]


> _______________________________________________
> testing-in-python mailing list
> testing-in-python at lists.idyll.org
> http://lists.idyll.org/listinfo/testing-in-python




More information about the testing-in-python mailing list