Dependency Error

When you run the application and you see error like this

Running "flutter pub upgrade" in Bookkart-flutter...
The current Flutter SDK version is 1.17.5.

Because bookkart_flutter depends on flutter_svg >=0.18.0 which requires Flutter SDK version >=1.18.0-6.0.pre <2.0.0, version solving failed. pub upgrade failed (1; Because bookkart_flutter depends on flutter_svg >=0.18.0 which requires Flutter SDK version >=1.18.0-6.0.pre <2.0.0, version solving failed.) Process finished with exit code 1

Error Possibilities:

Generally, this error occurs when

  1. one of your third party package version is not supported.
  2. your Flutter SDK version not matched with one of your third party packages. for ex, your current Flutter SDK version is 1.20.0 and third party package targets Flutter SDK version 1.17.0.

Solution:

 

After implementing the above solution, run the below command in the terminal.

flutter pub get