Android Studio - Unable to accept the Android Licenses

292 Views Asked by At

I'm having a problem accepting the Android Licenses. I've looked for well over a month for a solve and haven't found one yet. My username on my mac contains the word (Deleted) with a space before it and I'm wondering if that's causing any problems.

I run $ flutter doctor and get this result: enter image description here

I run $ flutter doctor --android-licenses

And I get this error:

Error: Could not find or load main class (Deleted).Library.Android.sdk.cmdline-tools.latest

I have all the SDK tools installed and updated to the latest. What I have installed is pictured below:

enter image description here

I have Java 8 installed and running, as well. Not getting any errors with Java.

Could use another pair of eyes to see what I'm doing wrong.

Here is my flutter doctor -v output: enter image description here

2

There are 2 best solutions below

8
On

First set android sdk path by flutter config --android-sdk <path-to-your-android-sdk-path> and run flutter doctor --android-licenses again

0
On

I have faced the same issued.

I have solved it by unistall Android Studio from control panel and re-install it again. So Android Studio can install the missing SDK packages.

I also found this article useful: https://docs.flutter.dev/get-started/install/windows#android-setup