【问题标题】:The file specified the interpreter is not an executable command指定解释器的文件不是可执行命令
【发布时间】:2021-10-06 03:12:07
【问题描述】:

我正在尝试使用 python 运行烧瓶应用程序。当我尝试pip install -r requirements.txt

我收到以下错误

   Failed to execute process '/Users/Kantemirovs/asdf/venv/bin/pip'. Reason:
The file '/Users/Kantemirovs/asdf/venv/bin/pip' specified the interpreter '/Users/Kantemirovs/asdf/venv/bin/python3', which is not an executable command.

有人可以帮我解决这个问题吗?

【问题讨论】:

  • 检查/Users/Kantemirovs/asdf/venv/bin/python3 是否存在。如果它是符号链接,请检查它指向的路径是否存在。当你升级你的系统 Python 时,经常会发生这样的事情,例如从 3.8 到 3.9,但 virtualenvs 中的符号链接一直指向不再存在的 3.8 可执行文件。在这种情况下,最简单的解决方案通常是从头开始重新创建 virtualenv。

标签: python terminal pip


【解决方案1】:

试试python -m pip install -r requirements.txt

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2011-03-01
    • 1970-01-01
    • 2013-12-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多