0

I'm trying to run a simple new Flutter project after following the steps from the flutter website, the flutter doctor saying everything is ok except some missing compoment from visual studio c++ but i'm using android studio which is ok. But when i run the project on android emulator i have this error. As you can see I think i have those tools installed already. Also i've tried cleaning and rebuilding and deleting the .gradle folder in my users directory but it gives the same error.

enter image description here

   Launching lib\main.dart on sdk gphone64 x86 64 in debug mode...
   Running Gradle task 'assembleDebug'...
   Checking the license for package Android SDK Build-Tools 30.0.3 in C:\Program Files 
   (x86)\Android\android-sdk\licenses
   License for package Android SDK Build-Tools 30.0.3 accepted.
   Preparing "Install Android SDK Build-Tools 30.0.3 (revision: 30.0.3)".
   Warning: Failed to read or create install properties file.
   Checking the license for package Android SDK Platform 31 in C:\Program Files 
   (x86)\Android\android-sdk\licenses
   License for package Android SDK Platform 31 accepted.
   Preparing "Install Android SDK Platform 31 (revision: 1)".
   Warning: Failed to read or create install properties file.

   FAILURE: Build failed with an exception.

   * What went wrong:
   Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
   > Failed to install the following SDK components:
      platforms;android-31 Android SDK Platform 31
      build-tools;30.0.3 Android SDK Build-Tools 30.0.3
   Install the missing components using the SDK manager in Android Studio.


   * 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 2m 29s
   Exception: Gradle task assembleDebug failed with exit code 1
  • Did you install the Android SDK Command lines tools? – jraufeisen Nov 17 '22 at 23:24
  • Does this answer your question? ["Failed to install the following Android SDK packages as some licences have not been accepted" error](https://stackoverflow.com/questions/54273412/failed-to-install-the-following-android-sdk-packages-as-some-licences-have-not) – jraufeisen Nov 17 '22 at 23:24
  • @jraufeisen yes the latest version 8.0 – Taunter exd Nov 17 '22 at 23:31

0 Answers0