Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
861 views
in Technique[技术] by (71.8m points)

firebase - Why flutter version solving failed between firebase_core and firebase_messaging?

In pubspec.yaml, if I use the following dependencies of firebase_core and firebase_messaging :

dependencies:

  firebase_core: ^0.7.0
  firebase_messaging: ^7.0.3

I get the following error message :

Because firebase_messaging >=7.0.3 <8.0.0-dev.7 depends on firebase_core ^0.5.0+1 and yourApp depends on firebase_core ^0.7.0, firebase_messaging >=7.0.3 <8.0.0-dev.7 is forbidden.
So, because youApp depends on firebase_messaging ^7.0.3, version solving failed.
pub get failed (1; So, because chat_app depends on firebase_messaging ^7.0.3, version solving failed.)
question from:https://stackoverflow.com/questions/65921970/why-flutter-version-solving-failed-between-firebase-core-and-firebase-messaging

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Update your pubspec.yaml according to the migration guide to FlutterFire : https://firebase.flutter.dev/docs/migration/

Caution: At the time of writting, FlutterFire Migration Guide does not compiled with firebase_core 0.7.0 and firebase_messaging 7.0.0, that's why I suggested to use firebase_messaging 8.0.0-dev :

dependencies:

  firebase_core: ^0.7.0
  firebase_messaging: ^8.0.0-dev.14

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...