I'm trying to install a package (dynamic_theme) in flutter. When I run flutter packages get -v
it does not even try to install the package.
So far I've tried:
flutter packages get
flutter packages get
In my pubspec.yaml I've put:
dependencies:
flutter:
sdk: flutter
firebase_core:
cupertino_icons: ^0.1.2
dynamic_theme: ^1.0.1 # the package does not install
uuid: 2.0.0 # the package does not install
In the logs for the verbose run of flutter packages get
where it installs the packages it outputs:
[ +422 ms] Running "flutter packages get" in quiz_app... (completed in 0.4s)
[ +57 ms] Found plugin firebase_core at E:\Other\SDKs\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core-0.3.4\
[ +13 ms] Found plugin shared_preferences at E:\Other\SDKs\flutter\.pub-cache\hosted\pub.dartlang.org\shared_preferences-0.5.2\
[ +141 ms] Found plugin firebase_core at E:\Other\SDKs\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core-0.3.4\
[ +6 ms] Found plugin shared_preferences at E:\Other\SDKs\flutter\.pub-cache\hosted\pub.dartlang.org\shared_preferences-0.5.2\
[ +26 ms] "flutter get" took 718ms.
I expected that flutter downloaded and installed the packages, but it does just check for updates on the already installed packages like firebase_core
.
Close and open your editor. Worked for me ;)
so basically run:
flutter clean
flutter packages get
flutter packages upgrade
Restart Android Studio or Visual Studio
you can restart VSC by:
ctrl + shift + P and then a search bar will appear and then type: "restart" and smash the Enter key.
hi I have a similar problem I deleted a package from the dart packages folder and when I run flutter pub run it won't download and work so I tried all the way people said but something worked for me is I tried to repairing pub cache and it worked just run
flutter pub cache repair
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With