gpt4 book ai didi

python - Pipenv 错误 "bad interpreter: No such file or directory"

转载 作者:行者123 更新时间:2023-12-04 16:43:06 26 4
gpt4 key购买 nike

我正在尝试从 pipfile 安装要求,但是当我键入 pipenv 并按 Enter 时,我收到此错误消息 -bash:/Users/jkelly/.local/bin/pipenv :/usr/local/Cellar/python/3.7.0/bin/python3.7:错误的解释器:没有这样的文件或目录 这个python目录不存在。我无法执行 pipenv。

python --version 返回 Python 3.6.6。我用 pyenv 管理我所有的 python 版本。

这是我所有 pyenv 垫片的完整列表

/Users/jkelly/.pyenv/shims/2to3
/Users/jkelly/.pyenv/shims/2to3-3.6
/Users/jkelly/.pyenv/shims/easy_install
/Users/jkelly/.pyenv/shims/easy_install-3.6
/Users/jkelly/.pyenv/shims/idle
/Users/jkelly/.pyenv/shims/idle3
/Users/jkelly/.pyenv/shims/idle3.6
/Users/jkelly/.pyenv/shims/pip
/Users/jkelly/.pyenv/shims/pip3
/Users/jkelly/.pyenv/shims/pip3.6
/Users/jkelly/.pyenv/shims/pydoc
/Users/jkelly/.pyenv/shims/pydoc3
/Users/jkelly/.pyenv/shims/pydoc3.6
/Users/jkelly/.pyenv/shims/python
/Users/jkelly/.pyenv/shims/python-config
/Users/jkelly/.pyenv/shims/python3
/Users/jkelly/.pyenv/shims/python3-config
/Users/jkelly/.pyenv/shims/python3.6
/Users/jkelly/.pyenv/shims/python3.6-config
/Users/jkelly/.pyenv/shims/python3.6m
/Users/jkelly/.pyenv/shims/python3.6m-config
/Users/jkelly/.pyenv/shims/pyvenv
/Users/jkelly/.pyenv/shims/pyvenv-3.6

pipenv 是通过 pipsi 安装的。这个错误似乎与 Pipfile 无关。我一定是某个地方的路径配置不正确。

export PATH=/Users/jkelly/.local/bin:$PATH
export PYENV_SHELL=bash
eval "$(pyenv init -)"
export PATH="/usr/local/opt/mongodb@3.6/bin:$PATH"
export PATH="/usr/local/opt/node@6/bin:$PATH"
export PATH="/usr/local/opt/gettext/bin:$PATH"

export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion

最佳答案

在 Mac OSX 上,我通过这样做解决了这个问题

brew install --force pipenv

然后

brew 链接 --overwrite pipenv

重新安装。

关于python - Pipenv 错误 "bad interpreter: No such file or directory",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55499356/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com