eslint_d.js
eslint_d.js copied to clipboard
Report issues back to client
Currently the stderr output and any exception thrown in the eslint_d
daemon are lost. It would be great to collect process.stderr
and catch global errors and report them back to clients.
Alternatively, we could try to find a good place to put logs – or at least let users configure a log output stream when starting the server so that we can trace issues better.
Ref #86
Hi, a user of SublimeLinter has from time to time "Error: ENOENT: no such file or directory, open /../eslint/node_modules/globals/index.js"
and resolves with eslint_d restart
. https://github.com/SublimeLinter/SublimeLinter-eslint/pull/327 Ideally I would like to get a message on stderr and restart automatically. (Or show a button so we don't dead-loop lint -> restart -> lint -> restart ...) Is that possible, or as this is a rather old issue already implemented?
I just spent several hours trying to figure out why emacs started to spit out this error:
Suspicious state from syntax checker javascript-eslint: Flycheck checker javascript-eslint returned 2, but its output contained no errors: Error: Cannot find module '.../node_modules/@eslint/eslintrc/node_modules/js-yaml/index.js'
Turns out there was a stale ~/.eslint_d
file. Also fixed by eslint_d restart
.
Some sensible feedback from the server would be really nice! ./
I'm currently too busy, but would help, review and accept PRs.
Things that can be improved:
- Improve client error message when unable to connect.
- Communicate server issues back to client.
- Add a
--log <file>
option for debugging purposes.
Help with any of those ideas would be appreciated. 🙏