2017-04-22 81 views
0

我有新的Ubuntu 17.04個很奇怪的問題,當我嘗試安裝從PIP我無法做到這一點的東西......這是錯誤:PIP setuptools的在Ubuntu 17.04失蹤

sudo pip install psutil 

The directory '/home/metu/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag. 
The directory '/home/metu/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag. 
Collecting psutil 
Downloading psutil-5.2.2.tar.gz (348kB) 
100% |████████████████████████████████| 358kB 1.3MB/s 
Could not import setuptools which is required to install from a source 
distribution. 
Traceback (most recent call last): 
File "/usr/lib/python2.7/dist-packages/pip/req/req_install.py", line 387, in setup_py 
import setuptools # noqa 
File "/usr/share/python-wheels/setuptools-32.3.1-py2.py3-none-any.whl/setuptools/__init__.py", line 10, in <module> 
File "/usr/share/python-wheels/setuptools-32.3.1-py2.py3-none-any.whl/setuptools/extern/__init__.py", line 1, in <module> 
ImportError: No module named extern 

這將會發生在我想要安裝的任何工具上。 beautifulsoap,燒瓶ECC ...

Python是版本:

Python 2.7.13 

皮普是最新版本:

pip 9.0.1 from /usr/lib/python2.7/dist-packages (python 2.7) 

setuptools的安裝:

sudo apt-get install python-setuptools 
python-setuptools is already the newest version (33.1.1-1). 

使用pycharm的包安裝正確,但我有很多庫包括,我不能一個一個地安裝d一些缺少像燒瓶登錄庫...

感謝所有幫助

回答

0

的extern需要,並沒有安裝所以下載的extern:

https://pypi.python.org/pypi/extern 

,並用命令來安裝它:

python setup.py install 

,如果問題沒有從點子

解決卸載的setuptools