3

I'm using nvim with kickstart configuration, I just added pyright for lsp and I'm editing a python file in the screenshot below.

I see this H in the left column, where can I find the documentation explaining it (with other symbols)?

nvim screenshot

What is the name of this left column where these symbols are shown? (so I can search the documentation for it too)

2 Answers 2

6

The symbols at the gutter are "signs" which is a recent feature of Vim and NeoVim, see :help sign-intro for more details on how it works. You can use the 'signcolumn' option to tweak it or disable it if you'd like.

In your specific case, the H is being generated by the vim.diagnostic NeoVim module which uses Vim signs to indicate diagnostics on specific lines of code. By default it uses the signs to indicate the severity of the diagnostic, where H stands for "Hint" (then going up in order of severity you'd have I for "Info", W for "Warning" and E for "Error".)

The diagnostics in case are coming from LSP, Pyright in your case. NeoVim has a vim.lsp.diagnostic module which feeds vim.diagnostic with the messages coming from your external LSP. So what this means is that Pyright is generating a "hint" for you in line 216 of your code.

NeoVim LSP should be showing you a message with what Pyright is telling you about that code line when you move your cursor or hover over that line. If for some reason you're having trouble with that, you can use something like :lua vim.diagnostic.open_float() with the cursor on that line to get it to tell you about that specific message. (See :help vim.diagnostic.open_float() for more details.)

3
  • 1
    Hoo boy… “recent” makes me feel old, and I’m not 😅 Good to see you answering questions again! Commented Jul 24, 2024 at 22:47
  • I guess "recent" taking into consideration the whole history of vi/vim/nvim which predates me :-D Commented Jul 25, 2024 at 4:17
  • 1
    Hmm, so it's "hint", yes I can see the messages, thank you so much for the detailed answer I'm going to read the documentation for this vim.diagnostic and the sign-intro too. Commented Jul 25, 2024 at 13:10
2

The name of that column is signcolumn.

More information with :help 'signcolumn'

I suspect you set a global mark using mH.

With the vim-signature plugin the marks are shown in the sign column.

You should be able to unset the H mark using: :delmark H.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.