-
Notifications
You must be signed in to change notification settings - Fork 27.9k
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
Freeze with problems panel with quick fixes #67694
Comments
The freeze is in The size of the |
Here's what I think is happening:
I don't think the markers panel should requests quick fixes for the entire document. Can we make this lazy instead, like how we request errors while moving the cursor through a file? As a workaround for now, we could also cap the number of code actions that |
@jrieken Do we need to call |
We need it for command arguments. When an "old" code action aka command comes it we track that because the arguments for that command aren't send to the main but stored on the ext-host side. Once the code action gets GC'ed (on the main side) we let go off the arguments. One trick would be to know if we have to do that, e.g a "modern" code action using text edits doesn't need this at all. But that only fixes half the problem, e.g old code actions still exist. A real fix would be the introduction of a proper lifecycle - we have done that with completions. |
To show light bulbs, problems panel is making single request per visible file to get code actions for complete file and compute it for each entry with the received data instead of asking code actions for each problem entry. @mjbvz I used the same example as yours with 250 problems and I do not see any freeze. Is there a different example to try out? |
Make sure you have the tslint plugin installed and have a recommended tslint config ( I don’t think we should be making these requests eagerly. Even without this bug, that’s a lot of extra communication and cycles for information we almost always discard. My proposal is to request the code actions for a single problem when you hover or focus the problem itself. |
Changed the strategy to fetch code actions when
code actions are fetched only once per marker irrespective of all above events. |
I have also pushed a change that gets rid of |
Repo
tslint --init
in an empty folderBug
Entire app freezes
The text was updated successfully, but these errors were encountered: