Ubuntu 16.04 安装Django时报错"python setup.py egg_info" failed with error code 1
2018-01-24 10:14
776 查看
Ubuntu pip安装Django(pip install Django)报错如下:
原因及解决办法如下:
安装时可指定setuptools的版本。这个办法对我没用。
2.换一种安装办法:python -m pip install Django
InsecurePlatformWarning Downloading Django-2.0.tar.gz (8.0MB) 100% |████████████████████████████████| 8.0MB 55kB/s Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 1, in <module> File "/tmp/pip-build-6jkxa3/Django/setup.py", line 32, in <module> version = __import__('django').get_version() File "django/__init__.py", line 1, in <module> from django.utils.version import get_version File "django/utils/version.py", line 61, in <module> @functools.lru_cache() AttributeError: 'module' object has no attribute 'lru_cache' ---------------------------------------- Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-6jkxa3/Django/
原因及解决办法如下:
解决办法:升级setuptools
pip install --upgrade setuptools
安装时可指定setuptools的版本。这个办法对我没用。
2.换一种安装办法:python -m pip install Django
imilano@ubuntu:~/Desktop/Blog$ python -m pip install Django
It worked!!!
参考链接:戳我相关文章推荐
- ubuntu 安装mysql 错误Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-lmPxC
- pip安装软件时出现Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build*的解决方案
- 解决 win10 pycurl安装出错 Command "python setup.py egg_info" failed with error code 10
- pip安装出现Command "python setup.py egg_info" failed with error code 1 的解决方案
- (未解决,只是提供一种思路)安装pyspider失败:Command "python setup.py egg_info"failed with error code 10 in.....
- pip安装jupyter时报错Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-Fd4ir0/
- pip安装软件时出现Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build*的解决方案
- pip安装icu失败:Command "python setup.py egg_info" failed with error code 1 in
- 安装第三方模板库发生错误:Command "python setup.py egg_info" failed with error code 1 in XXXXX
- 解决 win10 pycurl安装出错 Command "python setup.py egg_info" failed with error code 10
- pip安装出现Command "python setup.py egg_info" failed with error code 1 的解决方案
- pip安装软件时出现Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build*的解决方案
- 解决 win10 pycurl安装出错 Command "python setup.py egg_info" failed with error code 10
- python2.7 安装channels出现Command"python setup.py egg_info" failed with error code 1 in /tmp/pip-build-y
- pip安装软件时出现Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build*的解决方案
- 解决安装ipython时Command "python setup.py egg_info" failed with error code 1 in /tmp
- Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-o2julgbe/xgboost/
- 解决 Command "python setup.py egg_info" failed with error code 1 问题
- Python报错: python setup.py egg_info" failed with error code 1