flutter-ml / google_ml_kit_flutter

A flutter plugin that implements Google's standalone ML Kit
MIT License
918 stars 709 forks source link

Android Firebase Conflict - FAILURE: Build failed with an exception. #653

Open simeonangelov94 opened 4 weeks ago

simeonangelov94 commented 4 weeks ago

There is a conflict between the firebase dependencies and the google_mlkit_object_detection: ^0.13.0 package. If I don't add the google_mlkit_object_detection package the app compiles without an issue

cloud_firestore: ^5.0.2 firebase_auth: ^5.1.1 firebase_storage: ^12.1.0 firebase_core: ^3.1.1 firebase_messaging: ^15.0.2 firebase_app_check: ^0.3.0+2 google_mlkit_object_detection: ^0.13.0

FAILURE: Build failed with an exception.

simeonangelov94 commented 4 weeks ago

The conflict comes from having firebase_messaging: ^15.0.2 and google_mlkit_object_detection: ^0.13.0 packages in the yaml. When firebase_messaging: ^15.0.2 is removed there is no issue compiling for Android. Tried different build.gradle configuration but couldn't fix it.

fbernaly commented 3 weeks ago

Other developers have reported similar issues when using some of the ML Plugins in combination with some of the Firebase plugins. Sometimes their native dependencies are not compatible. In that case you need to reach out to Google and post the issue in their repos because they need to fix that.

simeonangelov94 commented 3 weeks ago

Do you have an idea where I can post this issue so the appropriate people can look into it?

fbernaly commented 3 weeks ago

https://github.com/googlesamples/mlkit/issues

ahndwon commented 3 weeks ago

Hello, have you found a solution?

simeonangelov94 commented 3 weeks ago

No the only solution was to remove one of the dependencies. Tried customizing the gradle file but unsuccessfully.

galizhan commented 3 weeks ago

same issue