当我使用pip安装时,它提示我“ ImportError:无法导入名称'cache_from_source'”

时间:2019-05-16 08:51:33

标签: python pip

当我使用pip安装时,它提示我“ ImportError:无法导入名称'cache_from_source'”

Traceback (most recent call last):
  File "E:\ruanjian2\python3\Scripts\pip-script.py", line 11, in <module>
    load_entry_point('pip==9.0.3', 'console_scripts', 'pip')()
  File "E:\ruanjian2\python3\lib\site-packages\pkg_resources\__init__.py", line
565, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "E:\ruanjian2\python3\lib\site-packages\pkg_resources\__init__.py", line
2631, in load_entry_point
    return ep.load()
  File "E:\ruanjian2\python3\lib\site-packages\pkg_resources\__init__.py", line
2291, in load
    return self.resolve()
  File "E:\ruanjian2\python3\lib\site-packages\pkg_resources\__init__.py", line
2297, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "e:\ruanjian2\python3\lib\site-packages\pip-9.0.3-py3.5.egg\pip\__init__.
py", line 43, in <module>
    from pip.utils import get_installed_distributions, get_prog
  File "e:\ruanjian2\python3\lib\site-packages\pip-9.0.3-py3.5.egg\pip\utils\__i
nit__.py", line 22, in <module>
    from pip.compat import console_to_str, expanduser, stdlib_pkgs
  File "e:\ruanjian2\python3\lib\site-packages\pip-9.0.3-py3.5.egg\pip\compat\__
init__.py", line 60, in <module>
    from importlib.util import cache_from_source
ImportError: cannot import name 'cache_from_source'

我的python版本是3.5.2,当我使用其他版本的python时没有发生

我想知道如何解决这个问题

0 个答案:

没有答案