gpt4 book ai didi

python - 如何为 python2.7 安装 pylint?

转载 作者:太空宇宙 更新时间:2023-11-03 13:58:53 24 4
gpt4 key购买 nike

我尝试为 ubuntu 18.04 中的 python2.7 安装 pylint,但它会引发错误:

pip install pylint                                  
Collecting pylint
Using cached https://pypi.tuna.tsinghua.edu.cn/packages/04/1f/1d3929051b45c3e4015178c5fe5bbee735fb4e362e0fc4f0fbf3f68647ad/pylint-2.1.1.tar.gz
pylint requires Python '>=3.4.*' but the running Python is 2.7.15

我已经使用pip3为python3.6成功安装了pylint。

那么,如何安装python2.7的pylint呢?

最佳答案

直到明年左右,pylint 仍会保持对 Python 2 的支持。但是您需要安装 1.9.X 而不是 2.X。似乎您已经安装了 pylint,一旦卸载它,您应该能够获得 1.9。

关于python - 如何为 python2.7 安装 pylint?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51746255/

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