Languageclient-neovim: Diagnostic signs remain in the gutter after fixing all errors

Created on 18 Jan 2018  ·  11Comments  ·  Source: autozimu/LanguageClient-neovim

Hi @autozimu,

I'm having erroneous diagnostic signs even after I fix all syntax errors in C++ code. If I move cursor to the line containing the sign, I don't see any error messages in the status line. Logs also show that the language server returns an empty list in textDocument/publishDiagnostics message. So I believe it's purely displaying issue.

nvim

  • neovim/vim version: NVIM v0.2.2
  • Plugin version (git SHA): ed183d77670538b4cdfbb9531a88e188e279b053
  • Minimal vimrc:
call plug#begin('~/.config/nvim/plugged')

Plug 'autozimu/LanguageClient-neovim', {
    \ 'branch': 'next',
    \ 'do': 'bash install.sh',
    \ }

call plug#end()

let g:LanguageClient_serverCommands = {
    \ 'cpp': ['clangd'],
    \ }
let g:LanguageClient_loggingLevel = 'DEBUG'
  • Language server name/link and version: latest clangd 7 from SVN. BTW stable clangd 5 doesn't work for me at all (probably due to #72 reintroduced in new rust implementation) but this is another story.
  • Reproduction steps (from clean state):
  1. Open the following C++ file with a syntax error:
#include <iostream>

void foo()
{

int main(int argc, char **argv)
{
    return 0;
}
  1. See the diagnostic signs because of missing closing brace.
  2. Fix the error by adding the missing brace to line 5.

Expected: all diagnostic signs disappear.
Observed: erroneous diagnostic signs still remain in the gutter.

This issue happens only in next branch. Legacy python implementation works correctly.

Thank you for your hard work!

Most helpful comment

I just started using this plugin and found I am I also experiencing this issue with javascript/typescript.

All 11 comments

I can confirm this, using rls and a more recent neovim. I'm using :sign unplace * as a workaround, since I have a binding to clear various visuals anyways.

Same with TypeScript or JavaScript projects.

A quick bisect reveals this was introduced in 2c56c546704943e20e9564ddc5d4f58c1c576e40

Not sure if related, but when working with RLS on the latest git of LanguageClient_neovim I sometimes get gutter signs that are one line off (so the actual errors are on a line right next to the gutter sign, and the error messages show up on the correct lines), and sometimes I get gutter signs where there are seemingly no errors (moving the cursor there doesn't make any error messages show up).

Ran into this today with typescript. Has this been fixed? Anybody else still getting this?

I just started using this plugin and found I am I also experiencing this issue with javascript/typescript.

I also still have signs and highlights that remain forever. Might this be a race condition with other plugins that handle the gutter?

Also see #295

I'm having this with Haskell (hie-wrapper), C++(clangd) and Python (pyls).
Is anyone still having this?

I am still seeing this, I opened a new issue #1008 with details

I also experiencing this issue with python3.6 (pyls server) and c (clangd-8 server).

Was this page helpful?
0 / 5 - 0 ratings