开发(例如Python 3.5)目标(例如Pylint)
我正在为 python3.5 目标编写代码。我无法控制我的开发环境,它最近升级到了 3.8。现在 pylint 会针对 python3.5 中不可用的功能(例如 f 字符串)吐出 100 条消息。
我没有 sudo 权限,所以我怀疑我是否可以安装自己的 3.5 二进制文件。我应该怎么办?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以尝试将
py-version
设置为3.5,在从Pylint上删除Python 3.5后添加的所有内容都不太可能有效,因此不要考虑python 3.5 ,但它适用于f-strings 。您也可以禁用有关Pylintrc中FSTRING的消息:You can try to set the
py-version
to 3.5, it's unlikely to work for everything as it was added after python 3.5 was dropped from pylint so not with python 3.5 in mind but it's going to work for f-strings. You could also disable the message concerning the fstring in your pylintrc: