HaxeFoundation / HaxeFoundation/haxe
[display] progess notifications for readClassPaths
- Dominant language
- Haxe
- Stars
- 6.9k
- Forks
- 715
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 11
Description
Now that the initialized flag is cleared when classpaths change, `readClassPaths` can end up being executed at the start of a completion request. Since the client didn't explicitly invoke `readClassPaths`, it can't display a progress indicator as it usually does and the user might be wondering why completion takes much longer than usual.
We could have some generic `progress/start` + `progress/done` notifications (basically a simplified version of the [LSP progress API](https://github.com/vshaxe/language-server-protocol-haxe/blob/master/src/languageServerProtocol/protocol/proposed/Progress.hx)) in the display protocol to help with this. Potentially there's also other things were that would be useful in the future.
---
Another option might be to instead notify the client when classpaths change, so the client can invoke `readClassPaths`. At first glance this sounds preferable as it could allow having `readClassPaths` run in the background and be done by the time completion is invoked the next time. However, in practice this probably doesn't work, Haxe could very well notice that classpaths have changed _during_ the completion request.
Contributor guide
Assessment
This issue has not been assessed yet.