[Distutils] the virtualenv-distribute mess

Reinout van Rees reinout at vanrees.org
Mon Oct 12 09:10:54 CEST 2009

On 2009-10-09, Tarek Ziadé <ziade.tarek at gmail.com> wrote:
> On Fri, Oct 9, 2009 at 2:03 PM, kiorky <kiorky at cryptelium.net> wrote:
>> AND no, virtualenv must continue to provide setuptools, backward
>> compatibility, you know?
> The *whole* point of Distribute 0.6.x is to be backward compatible, meaning
> that if virtualenv switch to it, you will not even notice it.

For something that's supposed to be a drop-in replacement, it sure makes it
self noticeable.  Note that I'm not holding that against distribute!  The mess
is of setuptools' making.

- When using buildout, I get lots of warnings.  The 1.4.2 isn't out yet, but I
  also won't update all old projects' pinned zc.buildout version so I'm stuck
  with warnings for a time.

- On every computer where I installed it, somehow (I haven't figured out how,
  yet), the system python's distutils-replaced setuptools egg was borked.  I
  had to revert the change and re-easy_install distribute (which worked
  afterwards).  The stuff I see when this happens:

    Downloading http://pypi.python.org/packages/2.5/s/setuptools/setuptools-0.6c9-py2.5.egg
    usage: -c [options] requirement_or_url ...
       or: -c --help

    error: invalid command 'easy_install'
    Traceback (most recent call last):
      File "bootstrap.py", line 49, in <module>
        ) == 0

- This weekend our buildbot (which I upgraded to use distribute) spit chunks
  all over me.  Nothing builds anymore since I upgraded.  Similar error as
  above.  This morning I did the "replace egg and easy_install distribute"
  dance in the buildbot slave's python dir and now it barfs with:

    Creating directory '/srv/buildbot.thehealthagency.com/parts/slave1/doctree.schemas_slave1/build/bin'.
    Creating directory '/srv/buildbot.thehealthagency.com/parts/slave1/doctree.schemas_slave1/build/parts'.
    Creating directory '/srv/buildbot.thehealthagency.com/parts/slave1/doctree.schemas_slave1/build/develop-eggs'.

    An internal error occured due to a bug in either zc.buildout or in a
    recipe being used:
    Traceback (most recent call last):
      File "/tmp/tmpTuZdd7/zc.buildout-1.4.1-py2.5.egg/zc/buildout/buildout.py", line 1659, in main
        getattr(buildout, command)(args)
      File "/tmp/tmpTuZdd7/zc.buildout-1.4.1-py2.5.egg/zc/buildout/buildout.py", line 363, in bootstrap
      File "build/bdist.linux-i686/egg/pkg_resources.py", line 621, in require
        needed = self.resolve(parse_requirements(requirements))
      File "build/bdist.linux-i686/egg/pkg_resources.py", line 519, in resolve
        raise DistributionNotFound(req)  # XXX put more info here
    DistributionNotFound: setuptools

I haven't been strangled yet by my colleagues for switching everything over.
I'm convinced we have to do it.  But I'd better fix it soon...

Any idea what these kinds of errors mean?  I can't believe I'm the only one.
It happened on my osx laptop and on the linux server and within a
buildout-installed buildbot.

Why oh why hasn't setuptools' pypi entry be transfered to distribute....


Reinout van Rees - reinout at vanrees.org - http://reinout.vanrees.org
Software developer at http://www.thehealthagency.com
"Military engineers build missiles. Civil engineers build targets"

More information about the Distutils-SIG mailing list