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.

analyzing takes for too long when writing any code in flutter !

See original GitHub issue

Describe the bug i am on ubuntu 20.04 and iam using dart and flutter with vs code and whenever i ever write any complex code it starts analyzing and it does that like non-stop over and over again so i have to write the code in a pad or whatever and paste it in vscode which is inconvenient at all ! To Reproduce Steps to reproduce the behavior: just by writing any complex code like Stream<List<NewsModel>> newsStream or using dartz like this Future<Either<T1,T2>>

Expected behavior it is expected to compile and analyze it as fast as possible in every code i write . Screenshots image

Versions :

  • VS Code version: 1.57.1
  • Dart extension version: 3.23.1
  • Dart/Flutter SDK version: Dart : 2.13.1 /Flutter : 2.2.1

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:14 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
DanTupcommented, Jun 28, 2021

Can you reliably reproduce this? If so, can you try:

  • delete the problematic code from the file and Save
  • enable the analysis server instrumentation log
  • restart VS Code
  • wait for initial analysis to completely finish
  • type the code that triggers the issue
  • take a copy of that log file

If there’s nothing sensitive in the log file, you can share it in a gist or email it to me at logs@dartcode.org. Otherwise, let me know and I can give you some instructions to find the useful parts from the log that might help understand what’s wrong.

There were some fixes in Flutter 2.2.2 that solve issues like this, however my understanding is that they only apply to macOS, so I don’t think it’s that - although it may be worth upgrading to that version just to be sure.

Thanks!

0reactions
DanTupcommented, Jun 29, 2021

I’ve filed https://github.com/dart-lang/sdk/issues/46505 about this as this appears to be a parser issue. I’ll close this one in favour of there, as it’s not something that can be fixed in the VS Code extension. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

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