Neovim 0.10 will have inlay hints (https://github.com/neovim/neovim/pull/23984), which are already supported on the nightly releases.
When enabled, the column offset for lsp lines sources are incorrect, as the inlay hints will shift the actual code to the right.
I assume (hope) there is a way for plugin authors to get feedback on which hints are inlayed for a given line, to allow calculating the needed offset for the start of a diagnostic span.
FYI it looks like this patch properly accounts for inlay hints (as well as any other inline virtual text).
0.10 is stable now. Are there any problems with the linked patch? It would be nice to have it merged so there’s no need to manually patch my local version.
Patched tested on 0.10.0 and applied.