我的ubuntu上有很多版本的python。我已使用别名将 python 命令的默认版本设置为 3.7。 我已经使用 virtualenvwrapper 创建了一个虚拟环境,并想在这个虚拟环境上安装 django。激活此虚拟后,如果我输入 python 命令,则会运行版本 3.7。但是如果我输入“pip install Django”,则会安装与 python 2.7 相关的旧版本 1.13。
我尝试使用“pip install Django==2.2.6”但没有成功。 它说:
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
如何强制 pip 安装与 python 3.7 相关的版本?
最佳答案
关于python - 如何强制 pip 安装最新版本的 django?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58473195/