AtomLinter/linter-jshint

Linter-jshint no longer reports errors?

Closed this issue · 3 comments

Two of my machines don't report any errors in my javascript code.

If I run jshint on the cmdline:

$ jshint gulpfile.js
gulpfile.js: line 471, col 7, Expected ':' and instead saw '='.
gulpfile.js: line 471, col 10, Expected '}' to match '{' from line 470 and instead saw ';'.
gulpfile.js: line 471, col 11, Missing semicolon.
gulpfile.js: line 471, col 10, Unrecoverable syntax error. (99% scanned).

4 errors

But in Atom it isn't reporting anything:
no-errors

I even tried completely removing Atom and reinstalling it, then restore all settings (via sync-settings) except anything related to linter.

Versions:
atom 1.30 (but I think this has been going on for a while)
linter 2.2.0
linter-jshint 3.1.8
jshint v2.9.6
nodejs v8.9.4

For completeness' sake, I checked with another linter plugin (linter-less) and that one does report errors in Atom:

less-has-errors

I think I found the problem. I had "Use Tree Sitter parser" enabled in Settings > Core. As soon as I turned that off linter-jshint started to report issues in my code.

Tree-sitter parsers for a while there changed the root scope of supported languages (For JavaScript, it changed from source.js to javascript) leading to things like this cropping up. That decision was reverted in the current v1.31.0 betas 😉.