1. Tarek Ziadé
  2. distribute
  3. Issues
Issue #74 resolved

use_setuptools() tries to patch the globally installed setuptools

Daniel Stutzbach
created an issue

Debian with Python 2.6. Setuptools 0.6c9 is installed in site-packages. I'm running a package's setup.py file that begins with the following:

{{{

!python

import distribute_setup distribute_setup.use_setuptools() }}}

The use_setuptools() function detects that setuptools is installed and attempts to patch it. This is not a nice thing for use_setuptools() to do, since the user is not trying to install distribute, they are just trying to install some other package that happens to make use of distribute for installation purposes. It especially should not be necessary for non-root activities such as "python setup.py test".

{{{

!python

otto:~/src/blist$ python2.6 setup.py test Scanning installed packages Setuptools installation detected at /usr/local/stow/Python-2.6.3/lib/python2.6/site-packages/setuptools-0.6c9-py2.6.egg Egg installation Patching... Renaming /usr/local/stow/Python-2.6.3/lib/python2.6/site-packages/setuptools-0.6c9-py2.6.egg into /usr/local/stow/Python-2.6.3/lib/python2.6/site-packages/setuptools-0.6c9-py2.6.egg.OLD.1255837298.17 Creating /home/agthorr/src/blist/setuptools-0.6c9-py2.6.egg-info Creating /home/agthorr/src/blist/setuptools.pth Traceback (most recent call last): File "setup.py", line 5, in <module> distribute_setup.use_setuptools() File "/home/agthorr/src/blist/distribute_setup.py", line 138, in use_setuptools fake_setuptools() File "/home/agthorr/src/blist/distribute_setup.py", line 389, in fake_setuptools res = _patch_egg_dir(setuptools_location) File "/home/agthorr/src/blist/distribute_setup.py", line 309, in _patch_egg_dir _rename_path(path) File "/home/agthorr/src/blist/distribute_setup.py", line 234, in _rename_path os.rename(path, new_name) OSError: [Errno 13] Permission denied

}}}

Comments (1)

  1. Log in to comment