I've run into a problem where easy_install/setuptools continues to recommend upgrading itself even after the upgrade has been installed. Steps to reproduce on CentOS 5.2:
include ~/python in PYTHONPATH include ~/bin in PATH
create ~/.pydistutils.cfg [install] install_lib = ~/python install_scripts = ~/bin
$ easy_install flup ... Running flup-1.0.3.dev-20090608/setup.py -q bdist_egg --dist-dir /tmp/easy_install-rPyZ6a/flup-1.0.3.dev-20090608/egg-dist-tmp-pm0o4x The required version of setuptools (>=0.6c9) is not available, and can't be installed while this script is running. Please install a more recent version first, using 'easy_install -U setuptools'.
(Currently using setuptools 0.6c5 (/usr/lib/python2.4/site-packages)) error: Setup script exited with 2 $ easy_install -U setuptools ... Processing dependencies for setuptools $ which easy_install ~/bin/easy_install $ python -c 'import setuptools; print setuptools.__version__' 0.6c9 $ easy_install flup ... Running flup-1.0.3.dev-20090608/setup.py -q bdist_egg --dist-dir /tmp/easy_install-WoxTch/flup-1.0.3.dev-20090608/egg-dist-tmp-oFotRt The required version of setuptools (>=0.6c9) is not available, and can't be installed while this script is running. Please install a more recent version first, using 'easy_install -U setuptools'.
(Currently using setuptools 0.6c5 (/usr/lib/python2.4/site-packages)) error: Setup script exited with 2
At this point I thought it might be a problem with flup's setup.py or ez_setup.py, but manually running python setup.py bdist_egg outside of easy_install works fine.
At 01:42 PM 6/11/2009 -0700, jason wrote:
(Currently using setuptools 0.6c5 (/usr/lib/python2.4/site-packages)) error: Setup script exited with 2 $ easy_install -U setuptools ... Processing dependencies for setuptools
You omitted the one part of the output that would tell us what the problem is; i.e. where the "easy_install -U setuptools" installed itself to. (Apparently, it's not /usr/lib/python2.4/site-packages!)
I omitted it from the output because I showed my ~/.pydistutils.cfg install_lib and PYTHONPATH pointing to ~/python which is where it correctly installed setuptools 0.6c9. easy_install went to ~/bin, which I also specified in ~/.pydistutils.cfg.
On Thu, 11 Jun 2009 20:45:04 -0400, "P.J. Eby" pje@telecommunity.com wrote:
At 01:42 PM 6/11/2009 -0700, jason wrote:
(Currently using setuptools 0.6c5 (/usr/lib/python2.4/site-packages)) error: Setup script exited with 2 $ easy_install -U setuptools ... Processing dependencies for setuptools
You omitted the one part of the output that would tell us what the problem is; i.e. where the "easy_install -U setuptools" installed itself to. (Apparently, it's not /usr/lib/python2.4/site-packages!)
At 02:34 AM 6/12/2009 -0700, jason wrote:
I omitted it from the output because I showed my ~/.pydistutils.cfg install_lib and PYTHONPATH pointing to ~/python which is where it correctly installed setuptools 0.6c9. easy_install went to ~/bin, which I also specified in ~/.pydistutils.cfg.
It doesn't matter why you omitted it. The point is, the place where the old version is installed (the one that's actually getting used) is clearly in site-packages:
At 01:42 PM 6/11/2009 -0700, jason wrote:
(Currently using setuptools 0.6c5 (/usr/lib/python2.4/site-packages))
On Thu, 11 Jun 2009 13:42:23 -0700, jason jason@mail.cornsyrup.org wrote:
The required version of setuptools (>=0.6c9) is not available, and can't be installed while this script is running. Please install a more recent version first, using 'easy_install -U setuptools'.
Hi Jason,
I get this problem all the time under windows....
What I do is use the Python Package Manager to remove setuptools (select setuptools 0.6c9 - click remove) and I also remove all of the easyinstall scripts from the scripts directory manually.
After that, I proceed to install the package again. In the process easyinstall gets installed again which reinstalls setuptools.
Regards
David