【问题标题】:Things such as pip work in regular windows terminal, but not in the VS Code terminal诸如 pip 之类的东西在常规 Windows 终端中有效,但在 VS Code 终端中无效
【发布时间】:2022-08-05 20:52:32
【问题描述】:

我正在尝试为 python 安装一些软件包。

我已将终端从 PS 更改为 Terminal。

我已经验证我在系统变量中有正确的路径。

我已验证别名已关闭。

我仍然有问题。

如果我开始,打开 cmd.exe 并输入“pip help”,我会得到我应该得到的帮助菜单。但是,当我尝试在 VS Code 的终端中运行它时,我得到

\'pip\' 不是内部或外部命令、可运行程序或批处理文件。

我在这里做错了什么?我已经检查了十几个不同的教程。我已经完全卸载了 VS Code 和 python。我很茫然。这里有什么问题?

我已经尝试过这里提供的“解决方案”:python and pip command not working in vs code integrted terminal but works in external terminal,但都没有奏效。

  • 您使用的是虚拟环境还是 conda 环境?

标签: python visual-studio-code terminal


【解决方案1】:

请在 vscode 设置中修改兼容性,并为 vscode 设置管理员权限。

【讨论】:

  • 我的解决方案能解决您的问题吗?
【解决方案2】:

尝试使用py -m pip 帮助因为我也有同样的问题而且它有效

【讨论】:

    猜你喜欢
    • 2017-03-29
    • 2021-01-22
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-12-23
    • 2012-04-02
    • 2013-08-07
    • 2021-07-18
    相关资源
    最近更新 更多