-
Notifications
You must be signed in to change notification settings - Fork 325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support notification progress instead of only status bar #1567
Comments
If you want to show progress in that scenario the progress should be initiated from the client side and then passed to the server since the progress is bound to a request. Server side progress in meant for "out of bound" progress. I am not sure if this is currently easily possible in the middleware. But I am open to have such a feature in the language client. |
These commands are Refactors so they are being invoked by the client. I believe they're already tied to a progress token from the client, but the language client seems to just treat all progresses the same and use Part of me thinks it'd be nice if LSP had a I see that only Any thoughts/opinions? |
I already see a behaviour like this on renaming files, for example. It would be great if any and all refactors got the same treatment! |
VS Code never binds a progress token to a provider call / request. The only exception right now is the initialize request in LSP. Because of that my proposal is that extensions can |
@dbaeumer I'm not sure I understand the suggestion. I'm not sure what difference injecting a token makes - it seems to just mean the progress is tied to that request rather than a server-created out-of-band progress (I don't think this makes any difference to me). I presume we'd need to change what's happening in |
While investigating a bug about progress notifications not showing during refactors, I found that this client always uses status bar notifications which are very subtle:
vscode-languageserver-node/client/src/common/progressPart.ts
Lines 61 to 62 in 0671381
While this is fine for something like background analysis, it's much less useful for something like an expensive refactor if a user drags a folder in explorer and it may take a few seconds to compute all the edits to update the imports. This would be better as a more visible notification.
@dbaeumer I'd be happy to implement this using middleware for my extension, but it's not clear if that's possible because this code lives inside
ProgressPart.begin()
. It would be nice to support it in the client though - maybe even the spec? I think the concept of a progress notification that is prominent because it is doing something important the user is explicitly waiting for could make sense (or, maybe the client could do it if the progress is tied to some kinds of requests, likeexecuteCommand
?).The text was updated successfully, but these errors were encountered: