[英]How can I fix this issue with SublimeLinter?
I hope it is ok to ask this even though it is not specifically a programming question.我希望可以问这个问题,即使这不是一个专门的编程问题。 I installed the
SublimeLinter
and SublimeLinter-flake8
packages in Sublime Text 3. I did pip install flake8
and restarted but the console shows the following message:我在 Sublime Text 3 中安装了
SublimeLinter
和SublimeLinter-flake8
包。我做了pip install flake8
并重新启动,但控制台显示以下消息:
SublimeLinter: WARNING: cannot locate 'flake8'.
SublimeLinter:警告:找不到“flake8”。 Fill in the 'python' or 'executable' setting.
填写“python”或“可执行”设置。 WARNING:SublimeLinter.lint.base_linter.python_linter:cannot locate 'flake8'.Fill in the 'python' or 'executable' setting
警告:SublimeLinter.lint.base_linter.python_linter:找不到'flake8'。填写'python'或'executable'设置
I suspect it may have to do with setting a path in the user settings, but I am not sure how to go about it.我怀疑这可能与在用户设置中设置路径有关,但我不知道如何 go 关于它。 As you may see I am a relative newbie.
如您所见,我是一个相对新手。 Thanks.
谢谢。
Please ensure you've followed these steps:请确保您已按照以下步骤操作:
Install SublimeText packages ( help )安装 SublimeText 包(帮助)
Install Flake8 (use pip
, or pip3
if you have multiple python versions)安装Flake8 (使用
pip
或pip3
如果您有多个 python 版本)
pip3 install flake8
flake8
settingsflake8
设置
Notice: Custom settings needs to be on the right(user) side!注意:自定义设置需要在右侧(用户)侧!
{
"linters": {
"flake8": {
"executable": [ "python3", "-m", "flake8" ]
}
}
}
Restart Sublime to enable the changes重新启动Sublime 以启用更改
Not sure about pip
or pip3
?不确定
pip
或pip3
吗? Please take a look at pip or pip3 to install packages for Python 3?请查看pip 或 pip3 来安装 Python 3 的软件包?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.