Flutter dependency error - Version Solving failed
This error happens because the integration_test
package in your pubspec.yaml
depends on flutter_driver, which required package crypto v3.0.1
, while the uuid
package you are using is at version 2.2.2, which required crypto v2.0.0
, hence the conflicting version on crypto
.
You should fix the versioning of the following packages in your pubspec.yaml
. It's best to update them to the latest to avoid the above conflict:
- uuid: ^3.0.4 (this package depends on crypto v3.0.1)
- integration_test: ^1.0.2+3 (this package depends on crypto v3.0.1 as well)
Shaurya Kohli
Updated on December 31, 2022Comments
-
Shaurya Kohli over 1 year
I'm trying out integration testing for my app. When I am trying to add the integration_test dependency to my pubspec.yaml I'm getting this error:
Because no versions of uuid match >2.2.2 <3.0.0 and uuid 2.2.2 depends on crypto ^2.0.0, uuid ^2.2.2 requires crypto ^2.0.0. And because every version of integration_test depends on flutter_driver any from sdk which depends on crypto 3.0.1, uuid ^2.2.2 is incompatible with integration_test. So, because flutter_firebase_login depends on both integration_test ^1.0.2+3 and uuid ^2.2.2, version solving failed. pub get failed (1; So, because flutter_firebase_login depends on both integration_test ^1.0.2+3 and uuid ^2.2.2, version solving failed.)
What should I do next to resolve this error?
-
Xoltawn almost 3 yearsjust update your packages. integration_test needs updated versions of your packages
-
Shaurya Kohli almost 3 years@Xoltawn you mean run the command pub upgrade first then try to run the command pub get?
-
Ravindra S. Patil almost 3 yearsTry to Change your package version
-