1

I'm installing from a Pip requirements file that looks like this:

Mezzanine==1.2.4
# psycopg2==2.4.5
South==0.7.6
django-compressor==1.2

mezzanine-mdown==0.1a3
Pygments==1.5

which results in this error (django-appconf is a dependency of django-compressor):

[...]
  Running setup.py install for django-appconf

  Found existing installation: setuptools 0.6c11
    Uninstalling setuptools:
Exception:
Traceback (most recent call last):
  File "/home/adambrenecki/lib/python2.7/pip/basecommand.py", line 107, in main
    status = self.run(options, args)
  File "/home/adambrenecki/lib/python2.7/pip/commands/install.py", line 261, in run
    requirement_set.install(install_options, global_options)
  File "/home/adambrenecki/lib/python2.7/pip/req.py", line 1162, in install
    requirement.uninstall(auto_confirm=True)
  File "/home/adambrenecki/lib/python2.7/pip/req.py", line 495, in uninstall
    paths_to_remove.remove(auto_confirm)
  File "/home/adambrenecki/lib/python2.7/pip/req.py", line 1492, in remove
    renames(path, new_path)
  File "/home/adambrenecki/lib/python2.7/pip/util.py", line 273, in renames
    shutil.move(old, new)
  File "/usr/local/lib/python2.7/shutil.py", line 300, in move
    os.unlink(src)
OSError: [Errno 13] Permission denied: '/usr/local/bin/easy_install'

The weird thing is, whenever I install django-compressor (or any of the others) individually, it doesn't do this. It's only when I use the requirements file.

The full command I'm using to install is pip-2.7 install --install-option="--install-scripts=/home/[username]/webapps/[appname]/bin" --install-option="--install-lib=/home/[username]/webapps/[appname]/lib/python2.7" -r requirements.txt. I'm on one of WebFaction's servers, if that helps.

Daisy Leigh Brenecki
  • 7,571
  • 6
  • 28
  • 43
  • Does any of your packages has setuptools newer than 0.6c11 as dependency? Because if any of they have, they are going to uninstall and then install the newer version. – Hugo Lopes Tavares Feb 18 '13 at 01:03
  • It ended up being something of the sort; in the end I just set up a virtualenv. I still don't get why each of the packages in my requirements.txt work individually but not when installed with `pip install -r`. – Daisy Leigh Brenecki Feb 19 '13 at 01:45

1 Answers1

-2

Looks like a permission issue as described by :

OSError: [Errno 13] Permission denied: '/usr/local/bin/easy_install'

Try to "sudo" your command.

EDIT : There is a note in WebFaction's documentation about "Permission Denied" error available at the following adress http://docs.webfaction.com/software/python.html (scroll to the bottom of the page).

Ketouem
  • 3,820
  • 1
  • 19
  • 29
  • I can't, I don't have superuser privileges - as noted in the question, this is on the server of a shared hosting provider. I can install each package individually without it even attempting to touch `easy_install`, just not when I use a requirements file. – Daisy Leigh Brenecki Feb 07 '13 at 09:18
  • Also, per your edit: As the path `pip` is trying to write to doesn't begin with `/tmp` (and `easy_install` isn't a temporary file), the note you reference doesn't apply either. – Daisy Leigh Brenecki Feb 19 '13 at 01:48