Open laukikk opened 3 years ago
I am having this issue, I think it is related with yours:
FAILURE: Build failed with an exception.
What went wrong: Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
In project 'app' a resolved Google Play services library dependency depends on another at an exact version (e.g. "[19.0. 0]", but isn't being resolved to that version. Behavior exhibited by the library will be unknown.
Dependency failing: com.google.firebase:firebase-ml-vision:20.0.0 -> com.google.firebase:firebase-ml-common@[19.0.0], bu t firebase-ml-common version was 22.0.0.
The following dependencies are project dependencies that are direct or have transitive dependencies that lead to the art ifact with the issue. -- Project 'app' depends on project 'firebase_ml_vision' which depends onto com.google.firebase:firebase-ml-vision@20.0. 0 -- Project 'app' depends onto com.google.firebase:firebase-ml-common@{strictly 22.0.0} -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language-translate@{strictly 22.0.0} -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language@22.0.0 -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language-language-id-model@{strictly 20.0.7} -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language-translate-model@20.0.7 -- Project 'app' depends onto com.google.firebase:firebase-ml-vision@{strictly 20.0.0} -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language@{strictly 22.0.0} -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language-translate-model@{strictly 20.0.7} -- Project 'app' depends onto com.google.firebase:firebase-ml-natural-language-language-id-model@20.0.7
For extended debugging info execute Gradle from the command line with ./gradlew --info :app:assembleDebug to see the dep endency paths to the artifact. This error message came from the google-services Gradle plugin, report issues at https:// github.com/google/play-services-plugins and disable by adding "googleServices { disableVersionCheck = true }" to your bu ild.gradle file.
Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
BUILD FAILED in 14s Exception: Gradle task assembleDebug failed with exit code 1
When I try to import the library i get the following error.
flutter run Using hardware rendering with device Android SDK built for x86. If you notice graphics artifacts, consider enabling software rendering with "--enable-software-rendering". Launching lib\main.dart on Android SDK built for x86 in debug mode... WARNING: [Processor] Library 'C:\Users\lauki.gradle\caches\modules-2\files-2.1\io.flutter\flutter_embedding_debug\1.0.0-5babba6c4d25fa237bbf755ab85c9a0c50b3c6ec\7034ab90ec0c221c3f95c61cec646ae4bcdbc225\flutter_embedding_debug-1.0.0-5babba6c4d25fa237bbf755ab85c9a0c50b3c6ec.jar' contains references to both AndroidX and old support library. This seems like the library is partially migrated. Jetifier will try to rewrite the library anyway. Example of androidX reference: 'androidx/annotation/NonNull' Example of support library reference: 'android/support/annotation/NonNull' C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\DeleteModel.java:3: error: package android.support.annotation does not exist import android.support.annotation.NonNull; ^ C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\DownloadModel.java:3: error: package android.support.annotation does not exist import android.support.annotation.NonNull; ^ C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\LanguageIdentifier.java:3: error: package android.support.annotation does not exist import android.support.annotation.NonNull; ^ C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\LanguageTranslator.java:3: error: package android.support.annotation does not exist import android.support.annotation.NonNull; ^ C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\ViewModels.java:3: error: package android.support.annotation does not exist import android.support.annotation.NonNull; ^ C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\DeleteModel.java:32: error: cannot find symbol public void onFailure(@NonNull Exception e) { ^ symbol: class NonNull C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\DownloadModel.java:36: error: cannot find symbol public void onFailure(@NonNull Exception e) { ^ symbol: class NonNull C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\LanguageIdentifier.java:62: error: cannot find symbol public void onFailure(@NonNull Exception e) { ^ symbol: class NonNull C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\LanguageTranslator.java:70: error: cannot find symbol public void onFailure(@NonNull Exception e) { ^ symbol: class NonNull C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\LanguageTranslator.java:61: error: cannot find symbol public void onFailure(@NonNull Exception e) { ^ symbol: class NonNull C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\LanguageTranslator.java:54: error: cannot find symbol public void onSuccess(@NonNull String translatedText) { ^ symbol: class NonNull C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\firebase_mlkit_language-1.1.2\android\src\main\java\io\flutter\plugins\firebase_mlkit_language\ViewModels.java:42: error: cannot find symbol public void onFailure(@NonNull Exception e) { ^ symbol: class NonNull 12 errors
FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':firebase_mlkit_language:compileDebugJavaWithJavac'.
Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
BUILD FAILED in 47s