Quick Clean Cache Open android studio Tools->Flutter->Clean. Go to File -> Invalidate Caches / Restart. Or open terminal run "flutter clean" Remove pubspec.lock.