[SciPy-dev] problems with numpy.setuptools("single_version_externally_managed")

David M. Cooke cookedm@physics.mcmaster...
Tue Sep 25 09:57:36 CDT 2007

dmitrey <dmitrey.kroshko@scipy.org> writes:

> hi all,
> If I use in setup.py:
> import setuptools
> from numpy.distutils.system_info import system_info, NotFoundError, 
> dict_append, so_ext
> I successfully install (OpenOpt) but Nils and I get the warning (with 
> latest numpy)
> ********************************************************
> distutils has been imported before numpy.distutils
> and now numpy.distutils cannot apply all of its
> customizations to distutils effectively.
> To avoid this warning, make sure that numpy.distutils
> is imported *before* distutils.
> ********************************************************
> (BTW note that distutils is not setuptools)

This is because of a recent change by Pearu. This is the right way to
do it with setuptools.

Pearu: I'm going to back your change out. For one thing, this is now

$ python setupegg.py bdist_egg
Running from numpy source directory.

I *think* (and I'll fix any bugs that don't correspond to this ;-)
that importing numpy.distutils after distutils is ok, as long as
you're not doing anything 'odd'. Basically, distutils isn't very
robust, so it's quite hard to tell what's a bad way to mix things.
But, we *do* explicitly support setuptools if it has been imported

|David M. Cooke              http://arbutus.physics.mcmaster.ca/dmc/

More information about the Scipy-dev mailing list