Autocomplete not working correctly in Android Studio with Flutter - First suggestions are irrelevant Autocomplete not working correctly in Android Studio with Flutter - First suggestions are irrelevant dart dart

Autocomplete not working correctly in Android Studio with Flutter - First suggestions are irrelevant


This problem can be fixed by one of the following

  1. Invalidate caches and Restart fixed my problem.Goto

File-> Ivalidate caches / Restart -> Invalidate and Restart

  1. Restart Dart Analysis Server. Follow the pic belowenter image description here

Note all above solutions works but are not permanent as it appears there is bug in latest dart Analysis server you can follow subscribe to this reported issue for more updates


Restart Dart Analysis Server :-

  1. Navigate to Dart Analysis tab at bottom.
  2. Click Restart Icon (red colored icon on top left corner of Dart Analysis Window)
  3. Wait for dart analysis to finish.

If it does not work, try this :-

  1. Delete .packages and pubspec.lock files present in your project folder
  2. run flutter pub get


In my case, I run in android studio terminal:

 flutter upgrade