python pip3找不到线程模块

时间:2017-05-07 16:35:38

标签: python multithreading python-3.x installation

我的ubuntu 14.04上有python 2.7.6和3.4.0。我想能够使用两者,因为一些作品是基于旧版本。我开始使用3并希望获得pip3来安装包。

当我尝试apt-get获取pip3时,它失败了。经过几次SO搜索后,有人建议用aptitude安装它,最终成功。

当我运行pip3时,我收到了这个错误,

Traceback (most recent call last):
  File "/usr/lib/python3.4/queue.py", line 4, in <module>
import threading
ImportError: No module named 'threading'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/pip3", line 9, in <module>
    load_entry_point('pip==1.5.4', 'console_scripts', 'pip3')()
  File "/usr/lib/python3/dist-packages/pkg_resources.py", line 351, in 
load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/lib/python3/dist-packages/pkg_resources.py", line 2363, 
in load_entry_point
    return ep.load()
  File "/usr/lib/python3/dist-packages/pkg_resources.py", line 2088, in load
entry = __import__(self.module_name, globals(),globals(), ['__name__'])
  File "/usr/lib/python3/dist-packages/pip/__init__.py", line 9, in <module>
    from pip.log import logger
  File "/usr/lib/python3/dist-packages/pip/log.py", line 8, in <module>
    from pip import backwardcompat
  File "/usr/lib/python3/dist-
packages/pip/backwardcompat/__init__.py", line 33, in <module>
from queue import Queue, Empty
  File "/usr/lib/python3.4/queue.py", line 6, in <module>
import dummy_threading as threading
  File "/usr/lib/python3.4/dummy_threading.py", line 45, in <module>
import threading
ImportError: No module named 'threading'

0 个答案:

没有答案