Open chances opened 1 year ago
Yeah, I think for error notifications like this we should do that. I think part of this is how serve-d uses the LSP API to send these notifications -- I don't think they are classed as "errors" needing to be acknowledged.
I know that for other ones, like the "Language server restarted." notification, they are meant to be auto-dismiss, because there is no further user action needed. But notices that need to be acknowledged or corrected should not automatically dismiss.
@webfreak001 - any ideas here?
these notifications are sent as error messages / have MessageType error - so probably a bug on your end? They stay there on vscode; unless of course it comes from restarting the language server, where it might clear the notifications from the previous run (vscode doesn't do that though, although there is no specification what to do)
Errors are displayed using nova'sworkspace.showErrorMessage
API and warnings are displayed using workspace.showWarningMessage
.
These don't provide any way to make the display modal. Nova claims it may bring the workspace to the foreground, but it says nothing about requiring confirmation, and there is no way to make them so using that API.
I think this is a limitation of Nova itself.
I'm going to close this for now, because there is no way I can do anything more with it. I'll also submit this to the Nova people.
One option here is to use a NotificationRequest instead of workspace.showErrorMessage
. It's not documented well, but if you don't add actions
the notification will auto-dismiss. But if you do add actions
the alert will stay on the screen until dismissed.
I use the dlang.org install script to install LDC. Nova has trouble finding my D installation in the environment. Regardless, this extension shows error notifications while trying to initialize the language server.
These notifications dismiss themselves after less than about 6 seconds. Notifications from Nova itself and other extensions let me read and dismiss them myself.