-
Notifications
You must be signed in to change notification settings - Fork 93
Add a generic progress start and update delay #549
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
Comments
This should let us get rid of a decent chunk of https://github.com/haskell/haskell-language-server/blob/b91c9076367123e983087ed305d183288a23f494/ghcide/src/Development/IDE/Core/ProgressReporting.hs#L108 |
Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not
Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not - Adapting to use the ghcide verison of `getCompletionPrefix` everywhere
Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not - Adapting to use the ghcide verison of `getCompletionPrefix` everywhere - Adapting to use the new mixed rope format
Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not - Adapting to use the ghcide verison of `getCompletionPrefix` everywhere - Adapting to use the new mixed rope format
Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not - Adapting to use the ghcide verison of `getCompletionPrefix` everywhere - Adapting to use the new mixed rope format
Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not - Adapting to use the ghcide verison of `getCompletionPrefix` everywhere - Adapting to use the new mixed rope format
* Bump lsp versions Broadly: - A few places where we need to pipe `ProgressToken`s around. - I also just removed the progress reporting from resolve commands, since it's going to often be costly to do progress reporting on something that short. Possibly we could revisit after haskell/lsp#549 - Some changes to the registration options we infer - A few places where we need to adapt to ignoring registrations or not - Adapting to use the ghcide verison of `getCompletionPrefix` everywhere - Adapting to use the new mixed rope format * stack * More fixes
Okay, I'm going to work on this for a little. |
Sounds good |
This is slightly annoying with the way it's currently done. In particular, at the moment we only do things when we get an update from the updater function, but once there are delays in the picture we probably need to wake up and send the last update that we saw every now and again, otherwise we might get quite bad behaviour. Which I think necessitates another thread handling that. So I need to refactor a bit. |
I did this |
At the moment we send progress start messages as soon as we can, and updates whenever we get them.
This means that:
We could potentially handle this generically: only send progress messages after a fixed interval has passed (should be configurable). In particular, if the operation terminates before we hit the first interval, we could send nothing.
This would let people declare most handlers to support progress and automatically get nice behaviour where progress is shown only if it takes a noticeable amount of time.
The text was updated successfully, but these errors were encountered: