-
Notifications
You must be signed in to change notification settings - Fork 183
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
Webstorm indexing and invalidation of generated implementations. #495
Comments
Thanks for reporting. One question, does it work to synchronize the project? (On my setup, Ctrl+Q). |
Should have mentioned that synchronize, does cause the generated.g.dart file to appear in the project panel, but not with indexing. That is to say that I see the file in the tree, but when I attempt to Hope this helps.... |
More Info I can also confirm that restarting the Dart Analysis Server, solves the issue... As a workaround that's much better (quicker) then invaliding the caches. |
Interesting. If it's visible in intellij but not picked up by the analyzer, then that sounds like an analyzer issue. If I understand correctly the analyzer is supposed to watch for file changes. What operating system are you on? I think that code is OS-dependent. I suggest filing over at https://github.com/dart-lang/sdk/tree/master/pkg/analyzer |
The plot thickens. I shall file in the analyzer project... Thanks for the input... Happy for this one to be closed... |
High Probability this issue does not belong here, but it may be falling through the crack across a number different projects.
Setup:
pubspec.yaml
IDE
Webstorm-2018.2.2 & EAP 2018.2.3
Situation
During a development workflow, it's not uncommon to create a new value object or modify an existing one, for example, the abstract below:
One can then run
pub run builder_runner build
, which works perfectly fine and produce that beautiful implementation of the abstract. 🥇Here is the rub, webstorm/dart analyzer does not appear to immediately recognize the generated file, in the case of the above
app_instance.g.dart
, it is visible in the directory tree, with red squiggly line.The underlying generated implementation class is fine; it is just not indexed.
The Workaround
One merely has to restart the IDE & invalidate the webstrom cache, using the menu option provided in webstrom.
Shortcomings
The above is very heavy handled given the regularity that one creates and changes value objects.
Is it your Environment
Have eliminated this by reproducing the issue in different containers and clean Mac OSX 10.13.6 environment.
Other Sightings
There appears to other issues with similar favours, hence the broad filling of this issue.
flutter/flutter#17353
dart-lang/sdk#34139
Also does not appear to any related issue on the webstorm forums.
The text was updated successfully, but these errors were encountered: