[Distutils] Alternative to the default easy-install setup?

skip at pobox.com skip at pobox.com
Mon May 3 14:25:37 CEST 2010

I suspect I've asked this before here but have forgotten the answer, so I
ask again.  We currently use easy_install at work to install most/all
third-party packages.  This causes problems because sys.path winds up
organized like this:

    3rd party stuff, followed by
    local stuff, followed by
    system stuff

As the number of third-party packages grows, the startup time for most
applications increases significantly because most of the modules and
packages of interest are actually in the local stuff or the system stuff.
If this was one or two applications running on a single machine it wouldn't
be bad.  When you add in NFS and try to start several hundred applications
across a multitude of hosts it's pretty easy to freeze the NFS server for a
non-trivial amount of time and extend startup times significantly.

Our current hack is to comment out the 

    import sys; new=...

line which easy_install adds to the end of easy-install.pth.  That's not
perfect, since the next time a third-party package is installed we have to
remember to do it again.  And again.  And again.  Eventually, no matter how
careful we are about this, someone forgets.

There must be something I can do to mitigate this problem.  Can all the
third-party eggs be bundled into a super package of some kind to minimize
all the file stat-ing?  Would some other installer (pip?  zc.buildout?) do
things differently?  Have I maybe missed some flags to easy_install which
would improve things?


Skip Montanaro - skip at pobox.com - http://www.smontanaro.net/

More information about the Distutils-SIG mailing list