In your pubspec.yml
change this to:
environment:
sdk: ">=2.8.0 <3.0.0"
and flutter pub get
in Android Studio invalidate the cache and restart, you should be good to go.
Credit : https://github.com/flutter/flutter/issues/62752#issuecomment-667744745