写pip后出现Frozen等错误,无法安装或卸载模块

问题描述 投票:0回答:1
C:\\WINDOWS\\system32\>pip --version
Traceback (most recent call last):
File "\<frozen runpy\>", line 198, in \_run_module_as_main
File "\<frozen runpy\>", line 88, in _run_code
File "C:\\Users\\user pc\\AppData\\Roaming\\Python\\Python311\\Scripts\\pip.exe_main_.py", line 4, in \<module\>
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\cli\\main.py", line 10, in \<module\>
from pip.\_internal.cli.autocompletion import autocomplete
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\cli\\autocompletion.py", line 10, in \<module\>
from pip.\_internal.cli.main_parser import create_main_parser
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\cli\\main_parser.py", line 9, in \<module\>
from pip.\_internal.build_env import get_runnable_pip
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\build_env.py", line 19, in \<module\>
from pip.\_internal.cli.spinners import open_spinner
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\cli\\spinners.py", line 9, in \<module\>
from pip.\_internal.utils.logging import get_indentation
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\utils\\logging.py", line 29, in \<module\>
from pip._internal.utils.misc import ensure_dir
File "C:\\Python311\\Lib\\site-packages\\pip_internal\\utils\\misc.py", line 37, in \<module\>
from pip.vendor.tenacity import retry, stop_after_delay, wait_fixed
File "C:\\Python311\\Lib\\site-packages\\pip_vendor\\tenacity_init_.py", line 27, in \<module\>
from concurrent import futures
File "C:\\Python311\\Lib\\site-packages\\concurrent\\futures\__init_.py", line 8, in \<module\>
from concurrent.futures.\_base import (FIRST_COMPLETED,
File "C:\\Python311\\Lib\\site-packages\\concurrent\\futures_base.py", line 357
raise type(self.\_exception), self.\_exception, self.\_traceback
^
SyntaxError: invalid syntax

我尝试过:

  • 卸载Python,然后安装到最新版本。
  • 升级点。
  • 降级Python。
  • 在命令提示符下使用 pip 安装和卸载模块。
  • 我什至更新了环境路径。

但仍然给出同样的错误。

这些错误的解决方案是什么?

python pip
1个回答
0
投票

解决了吗?我也面临同样的问题。

© www.soinside.com 2019 - 2024. All rights reserved.