collective/buildout.python

Error instaling python 2.6 n Ubuntu 12.04

Closed this issue · 5 comments

I'm trying to install only python 2.6 on Ubuntu 12.04.
Running buildout gives me the following:

'import site' failed; use -v for traceback Traceback (most recent call last): File "/home/alexandre/pzp/buildout.python/parts/virtualenv/virtualenv.py", line 2270, in <module> main() File "/home/alexandre/pzp/buildout.python/parts/virtualenv/virtualenv.py", line 928, in main never_download=options.never_download) File "/home/alexandre/pzp/buildout.python/parts/virtualenv/virtualenv.py", line 1029, in create_environment site_packages=site_packages, clear=clear)) File "/home/alexandre/pzp/buildout.python/parts/virtualenv/virtualenv.py", line 1180, in install_python import site File "/home/alexandre/pzp/buildout.python/parts/buildout/site.py", line 600, in <module> main() File "/home/alexandre/pzp/buildout.python/parts/buildout/site.py", line 582, in main known_paths = addusersitepackages(known_paths) File "/home/alexandre/pzp/buildout.python/parts/buildout/site.py", line 271, in addusersitepackages user_site = getusersitepackages() File "/home/alexandre/pzp/buildout.python/parts/buildout/site.py", line 246, in getusersitepackages user_base = getuserbase() # this will also set USER_BASE File "/home/alexandre/pzp/buildout.python/parts/buildout/site.py", line 235, in getuserbase from sysconfig import get_config_var ImportError: No module named sysconfig python-2.6: Non zero exit code (1) while running command. While: Installing python-2.6. Error: Non zero exit code (1) while running command.

It seems your PYTHONPATH is pointing to some Python 2.7 locations.

How to solve this? I used python 2.7 to run bootstrap.py... Is that it?

I wonder if this is related to #16 -- it seems there is a difference in PYTHONPATH introduced in latest bootstrap.py change.

I was having the same issue, but the problem was easy_install; I rerun the buildout using a virtualenv and everything worked as expected...

See #24 for a solution.