【问题标题】:Linter flake8 cannot find flake8, even though executablePath is specifiedLinter flake8 找不到 flake8,即使指定了 executablePath
【发布时间】:2020-07-05 11:02:36
【问题描述】:

我最近安装了 flake8 和 linter-flake8,我正在尝试在 Atom 中使用它。它没有安装在 PATH 上,所以我在 atom 上的 linter-flake8 包的设置中指定了可执行路径:

'linter-flake8':
  'executablePath': 'c:\users\user\appdata\local\packages\pythonsoftwarefoundation.python.3.8_qbz5n2kfra8p0\localcache\local-packages\python38\site-packages'

但仍然收到错误:“[Linter] Error running Flake8”。为什么找不到 flake8?

【问题讨论】:

  • 我最近遇到了这个问题。就我而言,我在 Atom 中安装了 linter-flake8 插件及其依赖项,但没有使用 pip install flake8 安装 flake8 本身。在我这样做并重新启动 Atom 之后,它工作了

标签: python atom-editor flake8


【解决方案1】:

根据README,您需要提供可执行文件的路径,而不是包含目录。

示例:

'linter-flake8':
  'executablePath': 'c:\users\user\appdata\...\site-packages\flake8.exe'

【讨论】:

  • 我是这样设置的,什么都没有,我仍然遇到同样的错误
猜你喜欢
  • 1970-01-01
  • 2018-02-07
  • 1970-01-01
  • 2022-12-24
  • 2018-11-12
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多