Languageclient-neovim: Regression: Signs do not disappear in gutter after line shifts.

Created on 6 Mar 2019  路  3Comments  路  Source: autozimu/LanguageClient-neovim

Description

Warning signs in gutter do not get deleted properly after deleting or inserting a line.
This was reintroduced in 0.1.141, 0.1.140 does not have this issue

To Reproduce

Steps to reproduce the behavior:

  • Open a valid python file, using python-language-server
  • Delete a line causing multiple syntax errors
  • Undo the change, reinserting the line

Current behavior

  • Warning signs in the gutter will remain

Expected behavior

  • Resolved warnings are cleared

Possible Cause

I think the problem was introduced by
https://github.com/autozimu/LanguageClient-neovim/blob/788e91931b9397cad047fed4c74811a62fdac1eb/src/sign.rs#L20-L23

Since the line number changes and causes the Equality check to fail.

Most helpful comment

In addition to signs not disappearing when inserting or deleting a line, they also persist after correcting the error in question. This in turn forces me to call signs unplace * after correcting an error in order for the signs to reflect the correct state of my code.

All 3 comments

In addition to signs not disappearing when inserting or deleting a line, they also persist after correcting the error in question. This in turn forces me to call signs unplace * after correcting an error in order for the signs to reflect the correct state of my code.

If anyone wants to see how it looks, this is it:

screenshot

Just wrote a simple script, making many errors along the way.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

macthecadillac picture macthecadillac  路  5Comments

norcalli picture norcalli  路  4Comments

languitar picture languitar  路  7Comments

martskins picture martskins  路  3Comments

ikneg picture ikneg  路  7Comments