Dieser Fehler wird angezeigt, während versucht wird, das Flutter-Projekt auszuführenAndroid

Forum für diejenigen, die für Android programmieren
Guest
 Dieser Fehler wird angezeigt, während versucht wird, das Flutter-Projekt auszuführen

Post by Guest »

Ich habe das Flutter SDK und Android Studio installiert und alles eingerichtet. Wenn ich jedoch versuche, das Projekt auszuführen, wird dieser Fehler angezeigt.
Flutter-Version: 3.27.1

Java-Version: 17.0.3

Fehlermeldung:

Code: Select all

Launching lib\main.dart on sdk gphone64 x86 64 in debug mode...
Checking the license for package Android SDK Platform 34 in C:\Users\LogithJ\AppData\Local\Android\Sdk\licenses
License for package Android SDK Platform 34 accepted.
Preparing "Install Android SDK Platform 34 (revision: 3)".
"Install Android SDK Platform 34 (revision: 3)" ready.
Installing Android SDK Platform 34 in C:\Users\LogithJ\AppData\Local\Android\Sdk\platforms\android-34
"Install Android SDK Platform 34 (revision: 3)" complete.
"Install Android SDK Platform 34 (revision: 3)" finished.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:processDebugResources'.
> A failure occurred while executing com.android.build.gradle.internal.res.LinkApplicationAndroidResourcesTask$TaskAction
> Android resource linking failed
aapt2.exe E 01-13 13:06:02  4124  1996 LoadedArsc.cpp:94] RES_TABLE_TYPE_TYPE entry offsets overlap actual entry data.
aapt2.exe E 01-13 13:06:02  4124  1996 ApkAssets.cpp:149] Failed to load resources table in APK 'C:\Users\LogithJ\AppData\Local\Android\Sdk\platforms\android-35\android.jar'.
error: failed to load include path C:\Users\LogithJ\AppData\Local\Android\Sdk\platforms\android-35\android.jar.

* 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 3m 10s
Running Gradle task 'assembleDebug'...                            191.9s

┌─ Flutter Fix ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ [!] Using compileSdk 35 requires Android Gradle Plugin (AGP) 8.1.0 or higher.                                                         │
│  Please upgrade to a newer AGP version. The version of AGP that your project uses is likely defined in:                               │
│ C:\Users\LogithJ\projects\\android\settings.gradle,                                                                 │
│ in the 'plugins' closure (by the number following "com.android.application").                                                         │
│  Alternatively, if your project was created with an older version of the templates, it is likely                                      │
│ in the buildscript.dependencies closure of the top-level build.gradle:                                                                │
│ C:\Users\LogithJ\projects\\android\build.gradle,                                                                    │
│ as the number following "com.android.tools.build:gradle:".                                                                            │
│                                                                                                                                       │
│  Finally, if you have a strong reason to avoid upgrading AGP, you can temporarily lower the compileSdk version in the following file: │
│ C:\Users\LogithJ\projects\\android\app\build.gradle                                                                 │
└───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
Error: Gradle task assembleDebug failed with exit code 1```

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post