【发布时间】:2014-08-06 09:01:11
【问题描述】:
在我遵循this 程序后,我遇到了问题
ImportError: No module named requests
当我
root@ubuntu:~# python -V
Python 2.7.8
当我
root@ubuntu:~# pip install requests
Requirement already satisfied (use --upgrade to upgrade): requests in /usr/local/lib/python2.6/dist-packages
Cleaning up...
看来我已经安装了requests,但是对于 python 2.6
编辑,我的系统是 Ubuntu 10.4,之前我通过 pip 安装了 requests
我有:
root@ubuntu:~# which python
/usr/local/bin/python
root@ubuntu:~# which easy_install
/usr/bin/easy_install
【问题讨论】:
-
which python和which easy_install的输出是什么? -
@Salem 问题已更新
-
删除并重新安装如何? sudo apt-get 删除请求,然后 sudo apt-get 安装请求。我知道包的名称可能不同。
-
@MarianPaździoch 在
/usr/local/bin中是否有任何名为pip或easy_install的文件? -
@Salem 是的,我有点子
标签: python-2.7 migration python-requests ubuntu-10.04