Issue #13 new

distribute failure

Aurélien Bompard
created an issue

I'm experiencing a problem with gp.recipe.pip which does not happen with another recipe (like zc.recipe.egg or z3c.recipe.scripts):

Here's my buildout.cfg :

{{{

!ini

[buildout] parts = mypython

[mypython]

recipe = zc.recipe.egg

recipe = gp.recipe.pip interpreter = mypython eggs = nose }}}

(any egg name I tried will cause the failure)

Here's what happens :

{{{

!sh

$ buildout-2.5 init Creating directory '/home/abompard/tmp/test-virtualenv/bin'. Creating directory '/home/abompard/tmp/test-virtualenv/parts'. Creating directory '/home/abompard/tmp/test-virtualenv/eggs'. Creating directory '/home/abompard/tmp/test-virtualenv/develop-eggs'. Getting distribution for 'distribute'. install_dir /home/abompard/tmp/test-virtualenv/eggs/tmpA349I2 warning: easy_install: byte-compiling is disabled, skipping. Got distribute 0.6.14. Getting distribution for 'zc.buildout'. install_dir /home/abompard/tmp/test-virtualenv/eggs/tmpvRGepp warning: easy_install: byte-compiling is disabled, skipping. Got zc.buildout 1.5.1. Generated script '/home/abompard/tmp/test-virtualenv/bin/buildout'. $ bin/buildout Getting distribution for 'gp.recipe.pip'. install_dir /home/abompard/tmp/test-virtualenv/eggs/tmpghKwJe warning: easy_install: byte-compiling is disabled, skipping. Got gp.recipe.pip 0.5.2. Getting distribution for 'pip'. install_dir /home/abompard/tmp/test-virtualenv/eggs/tmpgh0-TZ warning: no previously-included files matching '.txt' found under directory 'docs/_build' no previously-included directories found matching 'docs/_build/_sources' warning: easy_install: byte-compiling is disabled, skipping. Got pip 0.8. Getting distribution for 'virtualenv>=1.4'. install_dir /home/abompard/tmp/test-virtualenv/eggs/tmpdhulSi warning: no previously-included files matching '.*' found under directory 'docs/_templates' warning: easy_install: byte-compiling is disabled, skipping. Got virtualenv 1.4.9. Getting distribution for 'zc.recipe.egg'. install_dir /home/abompard/tmp/test-virtualenv/eggs/tmpOncRjc warning: easy_install: byte-compiling is disabled, skipping. Got zc.recipe.egg 1.3.2. Installing mypython. New python executable in /home/abompard/tmp/test-virtualenv/parts/pip/bin/python2.5 Also creating executable in /home/abompard/tmp/test-virtualenv/parts/pip/bin/python Installing distribute...... Complete output from command /home/abompard/tmp/test-virtua...on2.5 -c "#!python \"\"\"Bootstrap distribu...1:]) " --always-copy -U distribute: Traceback (most recent call last): File "<string>", line 20, in <module> ImportError: No module named tempfile


...Installing distribute...done. While: Installing mypython.

An internal error occurred due to a bug in either zc.buildout or in a recipe being used: Traceback (most recent call last): File "/home/abompard/tmp/test-virtualenv/eggs/zc.buildout-1.5.1-py2.5.egg/zc/buildout/buildout.py", line 1784, in main getattr(buildout, command)(args) File "/home/abompard/tmp/test-virtualenv/eggs/zc.buildout-1.5.1-py2.5.egg/zc/buildout/buildout.py", line 569, in install installed_files = self[part]._call(recipe.install) File "/home/abompard/tmp/test-virtualenv/eggs/zc.buildout-1.5.1-py2.5.egg/zc/buildout/buildout.py", line 1276, in _call return f() File "/home/abompard/tmp/test-virtualenv/eggs/gp.recipe.pip-0.5.2-py2.5.egg/gp/recipe/pip/init.py", line 211, in install return Scripts.install(self) File "/home/abompard/tmp/test-virtualenv/eggs/zc.recipe.egg-1.3.2-py2.5.egg/zc/recipe/egg/egg.py", line 145, in install reqs, ws = self.working_set() File "/home/abompard/tmp/test-virtualenv/eggs/gp.recipe.pip-0.5.2-py2.5.egg/gp/recipe/pip/init.py", line 147, in working_set use_distribute=True) File "/home/abompard/tmp/test-virtualenv/eggs/virtualenv-1.4.9-py2.5.egg/virtualenv.py", line 614, in create_environment install_distribute(py_executable, unzip=unzip_setuptools) File "/home/abompard/tmp/test-virtualenv/eggs/virtualenv-1.4.9-py2.5.egg/virtualenv.py", line 364, in install_distribute _install_req(py_executable, unzip, distribute=True) File "/home/abompard/tmp/test-virtualenv/eggs/virtualenv-1.4.9-py2.5.egg/virtualenv.py", line 337, in _install_req cwd=cwd) File "/home/abompard/tmp/test-virtualenv/eggs/virtualenv-1.4.9-py2.5.egg/virtualenv.py", line 587, in call_subprocess % (cmd_desc, proc.returncode)) OSError: Command /home/abompard/tmp/test-virtua...on2.5 -c "#!python \"\"\"Bootstrap distribu...1:]) " --always-copy -U distribute failed with error code 1 }}}

And indeed : {{{ $ ls parts/pip/lib/python2.5/*.py parts/pip/lib/python2.5/codecs.py parts/pip/lib/python2.5/ntpath.py parts/pip/lib/python2.5/site.py parts/pip/lib/python2.5/sre.py parts/pip/lib/python2.5/copy_reg.py parts/pip/lib/python2.5/os.py parts/pip/lib/python2.5/sre_compile.py parts/pip/lib/python2.5/stat.py parts/pip/lib/python2.5/fnmatch.py parts/pip/lib/python2.5/posixpath.py parts/pip/lib/python2.5/sre_constants.py parts/pip/lib/python2.5/types.py parts/pip/lib/python2.5/locale.py parts/pip/lib/python2.5/re.py parts/pip/lib/python2.5/sre_parse.py parts/pip/lib/python2.5/UserDict.py }}} -> no tempfile module.

If I run bin/buildout a second time however, it works fine (but still no tempfile module in parts/pip)

I don't understand what's going on.

This is on Mandriva 2010.1 (latest) with a backported python2.5, but I have the same problem on CentOS 5 with python 2.6.

If I can do anything to help debug this, please tell me.

Comments (1)

  1. BeProud

    For reasons unknown to me you can get around this issue by using buildout 1.5.0b2 and running buildout init -d before buildout from a clean installation.

    $ rm -Rf .installed.cfg eggs develop-eggs parts src
    $ python bootstrap.py
    $ ./bin/buildout init -d
    $ ./bin/buildout
    

    buildout 1.5.0 and up don't seem to work well with the pip recipe. A lot of monkeying around with the site directory paths seems to be the problem.

  2. Log in to comment