question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Do not start the Dart analysis server from the root if Dart projects are in subfolders

See original GitHub issue

This plugin always runs the analysis server from the root, resulting in a never terminating or hanging analysis in the dart-sdk. This is because the analyzer does not support analysis from the root of the dart-sdk project.

@dcharkes, thanks for the report! Generally, the use case of starting the analysis server from the root of the sdk is not supported.

@sjindel-google mentioned the Emacs plugin does not have the same issue, because it uses the .packages or pubspec.yaml files to determine from which folder to start analysis.

Would it be possible to get this behaviour in the VSCode plugin?

How to reproduce

  1. clone https://github.com/dart-lang/sdk
  2. open VSCode
  3. open the root folder of dart-lang/sdk
  4. enable Dart Code plugin

Analysis does not terminate, and generates 10000+ errors.

Expected behaviour

Analysis terminates normally (with a bunch of errors, as this is not a normal Dart project).

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:27 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
bwilkersoncommented, Jan 4, 2019

… should we open an analyzer issue? Or will it never be scheduled?

I don’t actually control the scheduling of analyzer issues, so I can’t say for sure. I think it’s worth opening an issue so that, if nothing else, we have some history in a place where we might be able to find it.

0reactions
DanTupcommented, Jan 4, 2019

Ok thanks, I’ll close this and leave it to you two to decide if there should be an analyzer issue. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Dart Analysis tool window | IntelliJ IDEA Documentation
Click this button to run the analysis of the Dart source code of the project without stopping the Dart Analysis server. Restart Dart...
Read more >
Linter rules - Dart
Use the Dart linter to identify possible problems in your Dart code. You can use the linter through your IDE or with the...
Read more >
Visual Studio Code Workspace Trust security
Workspace Trust. Visual Studio Code takes security seriously and wants to help you safely browse and edit code no matter the source or...
Read more >
flutter project files - Philadelphia Mixing Solutions
I want to be able to access it in the same file but in a different function when I am trying to access...
Read more >
Finding Unused Files With Dart Code Metrics - Medium
dart run dart_code_metrics:metrics check-unused-files lib# or for a Flutter package ... Since second_file.dart doesn't import any of the previous files, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found