-
-
Notifications
You must be signed in to change notification settings - Fork 123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Default gopls settings prevents diagnostics from being refreshed on InsertLeave #515
Comments
I found the culprit. When Lines 312 to 315 in fb612d1
This differs from |
go.nvim sets the trigger to 'Save' by default due to some seemingly broken logic[1]. This prevents diagnostics from being refreshed on InsertLeave as intended by Neovim (:h vim.diagnostic.Opts). [1]: ray-x/go.nvim#515
There is a gap between nvim and gopls setup. I am open to suggestions. |
I agree that The reason why I think The alternative is to send diagnostics to the location list with I got the behavior I wanted by setting |
Without
go.nvim
and usinggopls
defaults, LSP diagnostics are refreshed onInsertLeave
(ref.:h vim.diagnostic.Opts
).When using
go.nvim
with eitherlsp_cfg = true
orlsp_cfg = { settigns = { gopls = { ... } } }
, LSP diagnostics disappear upon entering Insert mode, and are only shown again upon saving the buffer.The text was updated successfully, but these errors were encountered: