Warning message if clangd not found not displayed ?

Christoph Cullmann (cullmann.io) christoph at cullmann.io
Wed Oct 5 22:55:34 BST 2022


On 2022-10-05 23:50, Alexander Neundorf wrote:
> On Sonntag, 2. Oktober 2022 17:01:24 CEST you wrote:
>> On 2022-10-02 14:23, Alexander Neundorf wrote:
>> > On Mittwoch, 28. September 2022 00:39:07 CEST Alexander Neundorf wrote:
>> >> Hi,
>> >>
>> >> I digged a bit into my clangd problems, and got a little bit further.
>> >> If clangd is not installed (it doesn't crash anymore, I think it did
>> >> in
>> >> older versions, that's good :-) ),
>> >> In LSPClientServerManagerImpl::_findServer() it ends up in the branch
>> >> "we didn't find the server at all!", where a warning should be
>> >> displayed
>> >> using showMessage(), but I can't see the warning. "LSP Client" ->
>> >> "More
>> >> Options" -> "Show Messages" is checked.
>> >> Where should the message appear ?
>> >
>> > ok, I found it. The message that clangd could not be started is as a
>> > warning
>> > in the "Output" tab, which I usually never open.
>> > I really looked closely at kate to find the message, and I found it
>> > only after
>> > digging into the sources. I would assume that many users will not see
>> > it.
>> >
>> > IMO this warning message is so important that the user needs to see it
>> > (because it means that "Switch header" does not work, which at least to
>> > me is
>> > essential in navigating between files).
>> > I could change it from Warning to Error, then the tab will by default
>> > be
>> > opened if the message is issued.
>> > This may happen multiple times, e.g. also for each different language.
>> > I could add a flag so that it is issued only once as error for every
>> > language,
>> > and then as warning afterwards ?
>> 
>> Hi,
>> 
>> I think we downgraded this to warning as it was super annoying to have
>> always the
>> output tab there.
>> 
>> On the other side, you now need to acknowledge the start the first 
>> time,
>> too, perhaps a first time error would make sense, too.
>> 
>> But the acknowledge is persistent, over application runs, I think the
>> same must be true for errors, if we want that.
> 
> how about the attached patch ?
> The user will see the error once per kate instance, which makes sense 
> to me.
> 
> If you think this is reasonable, I'll create a merge request etc.

Hi,

don't think that fits the bill, that is not persistent over sessions.
This means e.g. if you have no perl lsp, you will always get an error on 
startup,
that was the reason to make this just a warning in the past after people 
complained.

I would propose to rather make it more obvious there are unread 
warnings/errors in the output view
instead of annoying users more per default.

Greetings
Christoph


> 
> Alex

-- 
Ignorance is bliss...
https://cullmann.io | https://kate-editor.org


More information about the KWrite-Devel mailing list