Closed musicformellons closed 9 years ago
@musicformellons
This is only a guess.
Your current linux user probably does not have permission to write for any of the folders /home/usr/.cache/pip
You can try to rename /home/usr/.cache/pip
folder, delete or change the owner.
To recursively change the owner of the folder, do:
sudo chown -R username:username directory
in your case will be:
sudo chown -R usr:usr /home/usr/.cache/pip
and try again.
I think this can be caused by installing python packages globally, but using sudo
without the -H
option.
do:
sudo -H pip install foopackage
instead of:
sudo pip install foopackage
from sudo
docs
-H, --set-home
Request that the security policy set the HOME environment
variable to the home directory specified by the target user's
password database entry. Depending on the policy, this may
be the default behavior.
Having said that, this does not seem to be an issue of cookiecutter
or cookiecutter-django
if my guess solved the problem, please close this issue.
Solved. Great! BTW: I did not know about sudo -H, very helpful.
When installing requirements using pyenv-virtualenv with python 2.7.9 I get: usr@usr-XPS:~/goodplace$ pyenv activate goodplace (goodplace)usr@usr-XPS:~/goodplace$ pip install -r requirements/local.txt Collecting django==1.8.3 (from -r requirements/base.txt (line 1)) Using cached Django-1.8.3-py2.py3-none-any.whl Collecting django-environ==0.3.0 (from -r requirements/base.txt (line 2)) Collecting django-secure==1.0.1 (from -r requirements/base.txt (line 3)) Collecting whitenoise==2.0.2 (from -r requirements/base.txt (line 4)) Using cached whitenoise-2.0.2-py2.py3-none-any.whl Collecting django-braces==1.8.1 (from -r requirements/base.txt (line 5)) Using cached django_braces-1.8.1-py2.py3-none-any.whl Collecting django-crispy-forms==1.4.0 (from -r requirements/base.txt (line 6)) Collecting django-floppyforms==1.5.2 (from -r requirements/base.txt (line 7)) Collecting django-model-utils==2.3.1 (from -r requirements/base.txt (line 8)) Collecting Pillow==2.9.0 (from -r requirements/base.txt (line 9)) Collecting django-allauth==0.23.0 (from -r requirements/base.txt (line 10)) Collecting psycopg2==2.6.1 (from -r requirements/base.txt (line 11)) Collecting unicode-slugify==0.1.3 (from -r requirements/base.txt (line 12)) Collecting django-autoslug==1.8.0 (from -r requirements/base.txt (line 13)) Using cached django-autoslug-1.8.0.tar.gz Collecting pytz==2015.4 (from -r requirements/base.txt (line 14)) Using cached pytz-2015.4-py2.py3-none-any.whl Collecting django-redis==4.2.0 (from -r requirements/base.txt (line 15)) Using cached django-redis-4.2.0.tar.gz Collecting redis>=2.10.0 (from -r requirements/base.txt (line 16)) Using cached redis-2.10.3.tar.gz Collecting coverage==3.7.1 (from -r requirements/local.txt (line 2)) Using cached coverage-3.7.1.tar.gz Collecting Sphinx (from -r requirements/local.txt (line 3)) Using cached Sphinx-1.3.1-py2.py3-none-any.whl Collecting django-extensions==1.5.5 (from -r requirements/local.txt (line 4)) Using cached django_extensions-1.5.5-py2.py3-none-any.whl Collecting Werkzeug==0.10.4 (from -r requirements/local.txt (line 5)) Using cached Werkzeug-0.10.4-py2.py3-none-any.whl Collecting django-test-plus==1.0.7 (from -r requirements/local.txt (line 6)) Using cached django-test-plus-1.0.7.tar.gz Collecting factory-boy==2.5.2 (from -r requirements/local.txt (line 7)) Using cached factory_boy-2.5.2-py2.py3-none-any.whl Collecting django-debug-toolbar==1.3.2 (from -r requirements/local.txt (line 8)) Using cached django_debug_toolbar-1.3.2-py2.py3-none-any.whl Collecting ipdb==0.8.1 (from -r requirements/local.txt (line 9)) Using cached ipdb-0.8.1.zip Collecting gevent==1.1b2 (from -r requirements/local.txt (line 10)) Using cached gevent-1.1b2.tar.gz Collecting maildump==0.5.1 (from -r requirements/local.txt (line 11)) Using cached maildump-0.5.1.tar.gz Collecting six (from django-braces==1.8.1->-r requirements/base.txt (line 5)) Using cached six-1.9.0-py2.py3-none-any.whl Collecting requests-oauthlib>=0.3.0 (from django-allauth==0.23.0->-r requirements/base.txt (line 10)) Using cached requests_oauthlib-0.5.0-py2.py3-none-any.whl Collecting python-openid>=2.2.5 (from django-allauth==0.23.0->-r requirements/base.txt (line 10)) Using cached python-openid-2.2.5.tar.gz Collecting requests>=1.0.3 (from django-allauth==0.23.0->-r requirements/base.txt (line 10)) Using cached requests-2.7.0-py2.py3-none-any.whl Collecting unidecode (from unicode-slugify==0.1.3->-r requirements/base.txt (line 12)) Using cached Unidecode-0.04.18.tar.gz Collecting msgpack-python>=0.4.6 (from django-redis==4.2.0->-r requirements/base.txt (line 15)) Using cached msgpack-python-0.4.6.tar.gz Collecting sphinx-rtd-theme<0.2,>=0.1 (from Sphinx->-r requirements/local.txt (line 3)) Using cached sphinx_rtd_theme-0.1.8-py2.py3-none-any.whl Collecting snowballstemmer>=1.1 (from Sphinx->-r requirements/local.txt (line 3)) Using cached snowballstemmer-1.2.0.tar.gz Collecting Pygments>=2.0 (from Sphinx->-r requirements/local.txt (line 3)) Using cached Pygments-2.0.2-py2-none-any.whl Collecting docutils>=0.11 (from Sphinx->-r requirements/local.txt (line 3)) Using cached docutils-0.12.tar.gz Collecting babel>=1.3 (from Sphinx->-r requirements/local.txt (line 3)) Using cached Babel-2.0.tar.gz Collecting Jinja2>=2.3 (from Sphinx->-r requirements/local.txt (line 3)) Using cached Jinja2-2.8-py2.py3-none-any.whl Collecting alabaster<0.8,>=0.7 (from Sphinx->-r requirements/local.txt (line 3)) Using cached alabaster-0.7.6-py2-none-any.whl Collecting sqlparse (from django-debug-toolbar==1.3.2->-r requirements/local.txt (line 8)) Using cached sqlparse-0.1.16.tar.gz Collecting ipython>=0.10 (from ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached ipython-4.0.0-py2-none-any.whl Collecting greenlet>=0.4.7 (from gevent==1.1b2->-r requirements/local.txt (line 10)) Using cached greenlet-0.4.7.zip Collecting Flask (from maildump==0.5.1->-r requirements/local.txt (line 11)) Collecting Flask-Assets (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached Flask-Assets-0.10.tar.gz Collecting Logbook (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached Logbook-0.10.1.tar.gz Collecting beautifulsoup4 (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached beautifulsoup4-4.4.0-py2-none-any.whl Collecting cssmin (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached cssmin-0.2.0.tar.gz Collecting cssprefixer (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached cssprefixer-1.4.1.tar.gz Collecting cssutils (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached cssutils-1.0.zip Collecting gevent-socketio (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached gevent_socketio-0.3.6-py27-none-any.whl Collecting gevent-websocket (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached gevent-websocket-0.9.5.tar.gz Collecting html5lib (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached html5lib-0.999999.tar.gz Collecting lockfile (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached lockfile-0.10.2-py2-none-any.whl Collecting passlib (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached passlib-1.6.5-py2.py3-none-any.whl Collecting pyScss (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached pyScss-1.3.4.tar.gz Collecting python-daemon (from maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached python_daemon-2.0.5-py2.py3-none-any.whl Collecting oauthlib>=0.6.2 (from requests-oauthlib>=0.3.0->django-allauth==0.23.0->-r requirements/base.txt (line 10)) Using cached oauthlib-1.0.3.tar.gz Collecting MarkupSafe (from Jinja2>=2.3->Sphinx->-r requirements/local.txt (line 3)) Collecting decorator (from ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached decorator-4.0.2-py2.py3-none-any.whl Collecting simplegeneric>0.8 (from ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached simplegeneric-0.8.1.zip Collecting pexpect (from ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached pexpect-3.3.tar.gz Collecting traitlets (from ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached traitlets-4.0.0-py2.py3-none-any.whl Collecting pickleshare (from ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached pickleshare-0.5.tar.gz Collecting itsdangerous>=0.21 (from Flask->maildump==0.5.1->-r requirements/local.txt (line 11)) Collecting webassets>=0.10 (from Flask-Assets->maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached webassets-0.10.1.tar.gz Collecting enum34 (from pyScss->maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached enum34-1.0.4.tar.gz Collecting pathlib (from pyScss->maildump==0.5.1->-r requirements/local.txt (line 11)) Using cached pathlib-1.0.1.tar.gz Requirement already satisfied (use --upgrade to upgrade): setuptools in /home/usr/.pyenv/versions/goodplace/lib/python2.7/site-packages (from python-daemon->maildump==0.5.1->-r requirements/local.txt (line 11)) Collecting ipython-genutils (from traitlets->ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached ipython_genutils-0.1.0-py2.py3-none-any.whl Collecting path.py (from pickleshare->ipython>=0.10->ipdb==0.8.1->-r requirements/local.txt (line 9)) Using cached path.py-7.6-py2.py3-none-any.whl Building wheels for collected packages: django-autoslug, django-redis, redis, coverage, django-test-plus, ipdb, gevent, maildump, python-openid, unidecode, msgpack-python, snowballstemmer, docutils, babel, sqlparse, greenlet, Flask-Assets, Logbook, cssmin, cssprefixer, cssutils, gevent-websocket, html5lib, pyScss, oauthlib, simplegeneric, pexpect, pickleshare, webassets, enum34, pathlib Exception: Traceback (most recent call last): File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/site-packages/pip/basecommand.py", line 223, in main status = self.run(options, args) File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/site-packages/pip/commands/install.py", line 293, in run wb.build(autobuilding=True) File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/site-packages/pip/wheel.py", line 756, in build ensure_dir(output_dir) File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/site-packages/pip/utils/init.py", line 70, in ensure_dir os.makedirs(path) File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/os.py", line 150, in makedirs makedirs(head, mode) File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/os.py", line 150, in makedirs makedirs(head, mode) File "/home/usr/.pyenv/versions/goodplace/lib/python2.7/os.py", line 157, in makedirs mkdir(name, mode) OSError: [Errno 13] Permission denied: '/home/usr/.cache/pip/wheels/d2/44'