bootstrap 1.5.2, python2.6 and DistributionNotFound
Hi, I'm having problems using buildout on squeeze (that uses python 2.6). On ubuntu 12.10 (that uses python2.7) I have no problems. I'm still usig buildout 1.5.2 as I need a recipe for virtual env that is not yet available for buildout 2.+ (tl.buildout_virtual_python). When executing "python bootstrap" I'm getting: pkg_resources.DistributionNotFound: distribute This problem occurs also with a very simple conf that I found on the net when I started lunar.tar.gz, I uploaded the version I'm using here [1] after substituting bootstrap.py with a recent one. Here what I get: root@fw1-vpn-saa:/tmp/lunar/lunar# python bootstrap.py Downloading http://pypi.python.org/packages/2.6/s/setuptools/setuptools-0.6c11-py2.6.egg Creating directory '/tmp/lunar/lunar/bin'. Creating directory '/tmp/lunar/lunar/parts'. Creating directory '/tmp/lunar/lunar/eggs'. Creating directory '/tmp/lunar/lunar/develop-eggs'. Getting distribution for 'setuptools'. /usr/lib/python2.6/distutils/dist.py:266: UserWarning: Unknown distribution option: 'src_root' warnings.warn(msg) Got setuptools 1.1.4. Generated script '/tmp/lunar/lunar/bin/buildout'. root@fw1-vpn-saa:/tmp/lunar/lunar# bin/buildout Traceback (most recent call last): File "bin/buildout", line 17, in <module> import zc.buildout.buildout File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 40, in <module> import zc.buildout.download File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/download.py", line 20, in <module> from zc.buildout.easy_install import realpath File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/easy_install.py", line 31, in <module> import setuptools.package_index File "/usr/local/lib/python2.6/dist-packages/distribute-0.6.24-py2.6.egg/setuptools/package_index.py", line 157, in <module> sys.version[:3], require('distribute')[0].version File "build/bdist.linux-i686/egg/pkg_resources.py", line 673, in require File "build/bdist.linux-i686/egg/pkg_resources.py", line 576, in resolve dist = best[req.key] = env.best_match(req, self, installer) pkg_resources.DistributionNotFound: distribute If I use 'python bootstrap -d' that uses distribute, it will raise this error even on ubuntu 12.10/python2.7: root@fw1-vpn-saa:/tmp/lunar/lunar# python bootstrap.py -d Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.49.tar.gz Extracting in /tmp/tmpIsQPGq Now working in /tmp/tmpIsQPGq/distribute-0.6.49 Building a Distribute egg in /tmp/tmpkqSNaa /tmp/tmpkqSNaa/distribute-0.6.49-py2.6.egg Getting distribution for 'distribute'. warning: install_lib: 'build/lib.linux-i686-2.6' does not exist -- no Python modules to install Got distribute 0.7.3. While: Bootstrapping. An internal error occurred due to a bug in either zc.buildout or in a recipe being used: Traceback (most recent call last): File "/tmp/tmpkqSNaa/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 1866, in main getattr(buildout, command)(args) File "/tmp/tmpkqSNaa/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 399, in bootstrap ws.require('zc.buildout') File "build/bdist.linux-i686/egg/pkg_resources.py", line 698, in require needed = self.resolve(parse_requirements(requirements)) File "build/bdist.linux-i686/egg/pkg_resources.py", line 596, in resolve raise DistributionNotFound(req) DistributionNotFound: setuptools>=0.7 Any help is appreciated Thanks sandro [1] http://www.e-den.it/misc/lunar-sd.tar.gz
On Tue, Sep 10, 2013 at 07:44:05AM +0200, Alessandro Dentella wrote:
Hi,
I'm having problems using buildout on squeeze (that uses python 2.6). On ubuntu 12.10 (that uses python2.7) I have no problems.
I'm still usig buildout 1.5.2 as I need a recipe for virtual env that is not yet available for buildout 2.+ (tl.buildout_virtual_python).
BTW buildout 1.7.1 exists, and should be compatible with 1.5.x. Be sure you're using the latest version of pre-2.0 bootstrap.py by downloading it from http:/downloads.buildout.org/1/bootstrap.py
When executing "python bootstrap" I'm getting:
pkg_resources.DistributionNotFound: distribute
This problem occurs also with a very simple conf that I found on the net when I started lunar.tar.gz, I uploaded the version I'm using here [1] after substituting bootstrap.py with a recent one.
Here what I get:
root@fw1-vpn-saa:/tmp/lunar/lunar# python bootstrap.py Downloading http://pypi.python.org/packages/2.6/s/setuptools/setuptools-0.6c11-py2.6.egg Creating directory '/tmp/lunar/lunar/bin'. Creating directory '/tmp/lunar/lunar/parts'. Creating directory '/tmp/lunar/lunar/eggs'. Creating directory '/tmp/lunar/lunar/develop-eggs'. Getting distribution for 'setuptools'. /usr/lib/python2.6/distutils/dist.py:266: UserWarning: Unknown distribution option: 'src_root' warnings.warn(msg) Got setuptools 1.1.4. Generated script '/tmp/lunar/lunar/bin/buildout'. root@fw1-vpn-saa:/tmp/lunar/lunar# bin/buildout Traceback (most recent call last): File "bin/buildout", line 17, in <module> import zc.buildout.buildout File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 40, in <module> import zc.buildout.download File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/download.py", line 20, in <module> from zc.buildout.easy_install import realpath File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/easy_install.py", line 31, in <module> import setuptools.package_index File "/usr/local/lib/python2.6/dist-packages/distribute-0.6.24-py2.6.egg/setuptools/package_index.py", line 157, in <module> sys.version[:3], require('distribute')[0].version File "build/bdist.linux-i686/egg/pkg_resources.py", line 673, in require
File "build/bdist.linux-i686/egg/pkg_resources.py", line 576, in resolve dist = best[req.key] = env.best_match(req, self, installer) pkg_resources.DistributionNotFound: distribute
If I use 'python bootstrap -d' that uses distribute, it will raise this error even on ubuntu 12.10/python2.7:
root@fw1-vpn-saa:/tmp/lunar/lunar# python bootstrap.py -d Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.49.tar.gz Extracting in /tmp/tmpIsQPGq Now working in /tmp/tmpIsQPGq/distribute-0.6.49 Building a Distribute egg in /tmp/tmpkqSNaa /tmp/tmpkqSNaa/distribute-0.6.49-py2.6.egg Getting distribution for 'distribute'. warning: install_lib: 'build/lib.linux-i686-2.6' does not exist -- no Python modules to install Got distribute 0.7.3. While: Bootstrapping.
An internal error occurred due to a bug in either zc.buildout or in a recipe being used: Traceback (most recent call last): File "/tmp/tmpkqSNaa/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 1866, in main getattr(buildout, command)(args) File "/tmp/tmpkqSNaa/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 399, in bootstrap ws.require('zc.buildout') File "build/bdist.linux-i686/egg/pkg_resources.py", line 698, in require needed = self.resolve(parse_requirements(requirements)) File "build/bdist.linux-i686/egg/pkg_resources.py", line 596, in resolve raise DistributionNotFound(req) DistributionNotFound: setuptools>=0.7
Any help is appreciated
Use a virtualenv to give both distribute and setuptools >= 0.7 to buildout: virtualenv env env/bin/pip install -U setuptools env/bin/python bootstrap.py bin/buildout This works with both buildout 1.x and 2.x. Marius Gedminas -- Writing like a l33t script kiddie hax0r is the absolute kiss of death and guarantees you will receive nothing but stony silence (or, at best, a heaping helping of scorn and sarcasm) in return. -- ESR (http://www.tuxedo.org/~esr/faqs/smart-questions.html)
A partial solution in below On Tue, Sep 10, 2013 at 09:20:43AM +0300, Marius Gedminas wrote:
On Tue, Sep 10, 2013 at 07:44:05AM +0200, Alessandro Dentella wrote:
Hi,
I'm having problems using buildout on squeeze (that uses python 2.6). On ubuntu 12.10 (that uses python2.7) I have no problems.
I'm still usig buildout 1.5.2 as I need a recipe for virtual env that is not yet available for buildout 2.+ (tl.buildout_virtual_python).
It was already the correct one
BTW buildout 1.7.1 exists, and should be compatible with 1.5.x.
in fact in the example reported below I'm using that
Be sure you're using the latest version of pre-2.0 bootstrap.py by downloading it from http:/downloads.buildout.org/1/bootstrap.py
When executing "python bootstrap" I'm getting:
pkg_resources.DistributionNotFound: distribute
This problem occurs also with a very simple conf that I found on the net when I started lunar.tar.gz, I uploaded the version I'm using here [1] after substituting bootstrap.py with a recent one.
Here what I get:
root@fw1-vpn-saa:/tmp/lunar/lunar# python bootstrap.py Downloading http://pypi.python.org/packages/2.6/s/setuptools/setuptools-0.6c11-py2.6.egg Creating directory '/tmp/lunar/lunar/bin'. Creating directory '/tmp/lunar/lunar/parts'. Creating directory '/tmp/lunar/lunar/eggs'. Creating directory '/tmp/lunar/lunar/develop-eggs'. Getting distribution for 'setuptools'. /usr/lib/python2.6/distutils/dist.py:266: UserWarning: Unknown distribution option: 'src_root' warnings.warn(msg) Got setuptools 1.1.4. Generated script '/tmp/lunar/lunar/bin/buildout'. root@fw1-vpn-saa:/tmp/lunar/lunar# bin/buildout Traceback (most recent call last): File "bin/buildout", line 17, in <module> import zc.buildout.buildout File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 40, in <module> import zc.buildout.download File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/download.py", line 20, in <module> from zc.buildout.easy_install import realpath File "/tmp/lunar/lunar/eggs/zc.buildout-1.7.1-py2.6.egg/zc/buildout/easy_install.py", line 31, in <module> import setuptools.package_index File "/usr/local/lib/python2.6/dist-packages/distribute-0.6.24-py2.6.egg/setuptools/package_index.py", line 157, in <module> sys.version[:3], require('distribute')[0].version File "build/bdist.linux-i686/egg/pkg_resources.py", line 673, in require
File "build/bdist.linux-i686/egg/pkg_resources.py", line 576, in resolve dist = best[req.key] = env.best_match(req, self, installer) pkg_resources.DistributionNotFound: distribute
If I use 'python bootstrap -d' that uses distribute, it will raise this error even on ubuntu 12.10/python2.7:
root@fw1-vpn-saa:/tmp/lunar/lunar# python bootstrap.py -d Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.49.tar.gz Extracting in /tmp/tmpIsQPGq Now working in /tmp/tmpIsQPGq/distribute-0.6.49 Building a Distribute egg in /tmp/tmpkqSNaa /tmp/tmpkqSNaa/distribute-0.6.49-py2.6.egg Getting distribution for 'distribute'. warning: install_lib: 'build/lib.linux-i686-2.6' does not exist -- no Python modules to install Got distribute 0.7.3. While: Bootstrapping.
An internal error occurred due to a bug in either zc.buildout or in a recipe being used: Traceback (most recent call last): File "/tmp/tmpkqSNaa/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 1866, in main getattr(buildout, command)(args) File "/tmp/tmpkqSNaa/zc.buildout-1.7.1-py2.6.egg/zc/buildout/buildout.py", line 399, in bootstrap ws.require('zc.buildout') File "build/bdist.linux-i686/egg/pkg_resources.py", line 698, in require needed = self.resolve(parse_requirements(requirements)) File "build/bdist.linux-i686/egg/pkg_resources.py", line 596, in resolve raise DistributionNotFound(req) DistributionNotFound: setuptools>=0.7
Any help is appreciated
Use a virtualenv to give both distribute and setuptools >= 0.7 to buildout:
virtualenv env env/bin/pip install -U setuptools env/bin/python bootstrap.py bin/buildout
This works with both buildout 1.x and 2.x.
I noticed only after re-reading the mail that the error messag reported distributed from /usr/local/, I deleted that distribute egg and I could end my buildout. While this solves the case buildout uses setuptools, it leaves python+distribute fail. But that's a minor issue for me. sandro -- Sandro Dentella *:-) http://www.reteisi.org Soluzioni libere per le scuole http://sqlkit.argolinux.org SQLkit home page - PyGTK/python/sqlalchemy
participants (2)
-
Alessandro Dentella
-
Marius Gedminas