web-dev-qa-db-fra.com

Terminé avec une erreur: la tâche Gradle assembleDebug a échoué avec le code de sortie 1

Launching lib\main.Dart on HTC One M9PLUS in debug mode... Initializing gradle... Resolving dependencies... Gradle task 'assembleDebug'... registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:9: error: cannot find symbol import androidx.annotation.NonNull;
                          ^   symbol:   class NonNull   location: package androidx.annotation C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:10: error: cannot find symbol import androidx.annotation.Nullable;
                          ^   symbol:   class Nullable   location: package androidx.annotation C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:253: error: cannot find symbol
          public void onFailure(@NonNull Exception e) {
                                 ^   symbol: class NonNull C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:274: error: cannot find symbol
                    public Void apply(@NonNull Transaction transaction)
                                       ^   symbol: class NonNull C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:272: error: cannot find symbol
                    @Nullable
                     ^   symbol: class Nullable C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:503: error: cannot find symbol
                    public void onFailure(@NonNull Exception e) {
                                           ^   symbol: class NonNull C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-0.9.0\Android\src\main\Java\io\flutter\plugins\firebase\cloudfirestore\CloudFirestorePlugin.Java:558: error: cannot find symbol
                    public void onFailure(@NonNull Exception e) {
                                           ^   symbol: class NonNull 7 errors

FAILURE: Build failed with an exception.

* What went wrong: Execution failed for task ':cloud_firestore:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

* 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 26s Finished with error: Gradle task assembleDebug failed with exit code 1

J'ai juste essayé d'ajouter la base de feu au projet

4

l'erreur de Version du package Gradle Pour corriger Mettre à jour le package

Étape 1: Ouvrir le dossier Gradle Path C:\Users\{YourUserName}\.gradle\wrapper\dists puis Chick The Version.

S'il était ancien, mettez-le à jour depuis gradle.org

Téléchargement de la nouvelle version de Grandle

Téléchargez la dernière version Fichier Zip et décompressez-le en acceptant le remplacement des fichiers .

Et OPEN ANDRIOD STEDIO et exécutez

0
Omar bakhsh

Insérez ce chemin C:\Program Files\Android\Android Studio\jre\bin dans vos variables d'environnement [Variables système] may be it's work

0
Harshit Bisht