You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have checked existing issues and there are no existing ones with the same request.
Feature description
I understand that (deep in the weeds of) the documentation is describes that one can debug formatter failures as such:
check_exit_code=function(code, stderr)
localsuccess=code<=1ifnotsuccessthen-- can be noisy for things that run often (e.g. diagnostics), but can-- be useful for things that run on demand (e.g. formatting)print(stderr)
endreturnsuccessend,
However, I think this should be the default. Moreover, I speculate that most people aren't bothered by this not being the default because it is just a minor inconvenience - even though they'd indeed prefer it to be.
For example, when editing a large HTML file using none-ls, prettier may just silently fail, my LSP will not be able to tell what's happening, and the only logical thing is to :!prettier % to debug the error.
I've updated my config here and it works fine, but it really is polluted (and there's an LSP timeout error):
Note that some external formatting tools will exit with a non-zero status if checks aren't passing (but fix them anyway), while others don't. If we'd like to use this as the default behavior, we need to review all the builtins and ensure the corresponding behavior.
Aside from that, I think adding check_exit_code to helpers should be a good start.
You can start implementing the changes.
Issues
Feature description
I understand that (deep in the weeds of) the documentation is describes that one can debug formatter failures as such:
However, I think this should be the default. Moreover, I speculate that most people aren't bothered by this not being the default because it is just a minor inconvenience - even though they'd indeed prefer it to be.
For example, when editing a large HTML file using
none-ls
, prettier may just silently fail, my LSP will not be able to tell what's happening, and the only logical thing is to:!prettier %
to debug the error.I've updated my config here and it works fine, but it really is polluted (and there's an LSP timeout error):
I think this is a sensible default choice but let me know if y'all think otherwise.
Help
Yes
Implementation help
Willing (and would prefer) to help.
The text was updated successfully, but these errors were encountered: