错误:产生pycodestyle ENOENT

时间:2017-02-07 11:22:12

标签: atom-editor autopep8

安装了linter-pep8后出现此错误。

Error: spawn pycodestyle ENOENT
at exports._errnoException (util.js:1026:11)
at Process.ChildProcess._handle.onexit (internal/child_process.js:193:32)
at onErrorNT (internal/child_process.js:359:16)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)

1 个答案:

答案 0 :(得分:24)

错误是由包从 linter-pep8 重命名为 linter-pycodestyle v2.0.0

引起的

<强>解决方案

  1. 卸载 pep8 sudo pip uninstall pep8
  2. 卸载 pycodestyle sudo pip uninstall pycodestyle
  3. 再次安装 pycodestyle sudo pip install pycodestyle
  4. 卸载ATOM linter-pep8 apm uninstall linter-pep8
  5. 安装ATOM linter-pycodestyle apm install linter-pycodestyle
  6. 通过在终端中执行which pycodestyle来检查是否正确安装了 pycodestyle 。它应返回 pycodestyle 的路径(例如/usr/local/bin/pycodestyle)。您可以在原子&#39;的可执行路径设置中设置此路径。 linter-pycodestyle 包 - 但它应该默认使用
相关问题