简体   繁体   中英

Flutter dependency error - Version Solving failed

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?

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:

  1. uuid : ^3.0.4 (this package depends on crypto v3.0.1)
  2. integration_test : ^1.0.2+3 (this package depends on crypto v3.0.1 as well)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM