Skip to content
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

fix: VSCode With Incompatible dart_frog Version Causes Poor Performance #1139

Open
a-wallen opened this issue Nov 11, 2023 · 5 comments
Open
Labels
bug Something isn't working as expected p2 Important issues not at the top of the work list

Comments

@a-wallen
Copy link

Description

I've been experiencing very poor performance in VSCode for the last week or so. Whenever I opened the application for work, I'd get a popup message saying something like

This version of dart_frog is incompatible with this workspace

I couldn't use project search, my intellisense barely worked, and even fast file search took so long to load.

image

Then I took a look at the extensions that I had running and dart_frog was still initializing which is what I think is causing these performance issues.
image

Steps To Reproduce
I'm using flutter 3.10.1 in a frontend project (no dart_frog), but the extension is installed and my dart_frog version is 0.3.6.

Expected Behavior

If we can't use dart_frog in the project and I dismiss the warning message, that means I don't care about using dart_frog in this project so the plugin shouldn't be initialized.

@a-wallen a-wallen added the bug Something isn't working as expected label Nov 11, 2023
@a-wallen
Copy link
Author

For further context, as soon as I uninstalled the plugin I had great performance - so I'm almost sure it's coming from the VSCode extension. I have a great CPU so I was baffled that VSCode's performance was so slow for the past week.

@alestiago
Copy link
Contributor

Thanks, @a-wallen for opening this issue! I will look into it and get back to you as soon as possible 🙌

@alestiago alestiago assigned alestiago and unassigned alestiago Nov 13, 2023
@alestiago
Copy link
Contributor

alestiago commented Nov 20, 2023

Hi @a-wallen , I've just started looking into this. The Dart Frog CLI version you are using is not compatible with the Dart Frog VS Code extension. Upon activation you should be getting a window suggesting to update. I do understand that you currently want to be in the pinned Dart Frog CLI version. Currently, the compatibility constraints is ">=1.1.1 <2.0.0".

As per the documentation:

If the version of Dart Frog CLI installed in the user's system is not compatible with this extension, the user is prompted to update Dart Frog CLI or ignore the warning. If the user chooses to update Dart Frog CLI, the extension will attempt to update Dart Frog CLI. Otherwise, the user will proceed to use the extension at their own risk.

Hence, if you are ignoring this, you are proceeding at your own risk.

A solution to this issue could be disabling all Dart Frog VS Code functionalities if the compatibility constraints are not met. So instead of letting users proceed at their own risk, we would be disabling all Dart Frog VS Code functionalities until the compatibility constraints are met. I'll discuss this with the team and see what we proceed with. In the meantime, you can disable the extension and/or comment your opinion about this proposed solution or a new proposed solution.

@a-wallen
Copy link
Author

IMO, I think the second option (disabling if incompatible) is the best way to proceed because I get like 5 popup notifications every time I open VSCode and I just want to start coding. Plus, the project that I was working was unrelated to dart_frog so I dismissed the notification because I didn't think that it was relevant for what I was currently working on. Is it possible to disable for just that session if I dismiss the notification?

@alestiago alestiago removed their assignment Dec 5, 2023
@alestiago
Copy link
Contributor

alestiago commented Dec 14, 2023

We will be going with the second option (disabling if incompatible). This is not something we are heavily prioritising for the time being since we have limited bandwidth. If you would like to contribute with this change let us know so we can assign it to you. If so, we recommend reading the CONTRIBUTING and then the team will happily review your Pull Request.

As a temporary solution, when you're using an incompatible Dart Frog CLI "disable" the extension from VS Code. When you're using a compatible Dart Frog CLI enable it again.

@alestiago alestiago added the p2 Important issues not at the top of the work list label Feb 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working as expected p2 Important issues not at the top of the work list
Projects
Status: Backlog
Development

No branches or pull requests

2 participants