What happened?
When using lsp “code actions” when writing Dart code, there is about a 10 second delay.
First of all, I’m not really unhappy with the overall performance of Doom Emacs. Maybe my standards are low or something. I can see the difference between Doom Emacs and Neovim, but it doesn’t generally bother me much. Maybe I haven’t hit the right scenario yet.
Second, everything seems to work. If anything is missing, I just don’t know about it. My LSP is working, formatting, highlighting, everything
Finally, the actual problem: When I use LSP “code actions”, for example “wrap x widget in y widget”, it works, but there’s about a 10 second delay, during which the UI locks up. It always completes successfully, but actually gives an error “Timeout while waiting for response.”
Again, despite the error message, it actually completes successfully.
What did you expect to happen?
I expect the code action to complete without a 10s delay or an error message.
{{{Explain what should have happened.}}} What should have happened is a relatively prompt code action without a timeout error.
Steps to reproduce
- Correctly install and use an LSP for a Dart project. I guess there’s room for doubt about how “correct” my config is. I’ll post it below, as required. 2 Start a dart/flutter project 3 Verify that code actions work.
- Notice that they (code actions) take a really long time to complete, and give an error message despite successfully completing.
Notes:
- Flutter’s lsp code actions work instantaneously for me in other editors on the same system.
- I couldn’t reproduce this in other languages, because I wasn’t able to utilize any “code actions” in them. I’ve never used code actions before in any editor before trying them in dart. When I open old projects written in python or java or whatever, I’ll kind of scroll through, looking for places I can apply code actions just to test, and can’t find any. I’m not sure if that’s a configuration problem, or just there aren’t any code actions available. I came from Jetbrains products, which probably explains a lot.
System information
Loading data dump...