python pip 出错解决办法
作者:互联网
pip 不知是否升级时出错了:
C:\>pip install
Traceback (most recent call last):
File "e:\python38\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "e:\python38\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "E:\Python38\Scripts\pip.exe\__main__.py", line 4, in <module>
ModuleNotFoundError: No module named 'pip._internal'
解决办法:
到PyIP网站下载适合版本的pip版本如:pip-21.0-py3-none-any.whl
将下载的文件加.zip: pip-21.0-py3-none-any.whl.zip 再解压这个zip文档到目录pip-21.0-py3-none-any.whl:
删除原有的相应文件,把这两个目录copy到 \python38\Lib\site-packages 下即解决问题:
结果如下:
标签:code,21.0,python,py3,whl,出错,pip,any 来源: https://blog.csdn.net/skyyzq/article/details/113413844