190 likes | 195 Views
When Running a flutter mobile application sometimes the compiler randomly starts giving an error that states u201cYou have not accepted the license agreementsu201d. So, in this article, we will get into How to Solve u201cYou have not accepted the license agreementsu201d.
E N D
How to Solve “You have not accepted the license agreements”?
When Running a flutter mobile application sometimes the compiler randomly starts giving an error that states “You have not accepted the license agreements”. So, in this article, we will get into How to Solve “You have not accepted the license agreements”.
How to Solve “You have not accepted the license agreements”?
To solve this error user can give try to below code. 1. Open your terminal 2. type flutter doctor –android-licenses 3. Press y to accept every license.
The only command that worked & solved the issue was: (your android_sdk folder path)\tools\bin\sdkmanager --licenses
You can also execute the steps below: • So, execute the command prompt as administrator. • After that run the command flutter doctor – android-licenses and accept all licenses. • Run the command flutter doctor -v to check if the issue was solved. • To make sure that is everything is ok, execute the command prompt as a regular user (your user) and execute flutter doctor -v again.
If you are in windows open the command prompt as admin and run the following command. flutter doctor --android-licenses
Then enter y for all (y/n) to accept the agreement. For newer installations (especially on macOS) flutter doctor –android-licenses does not work. Run the following command (notice the new path to SDK cmd-line tools) and you will be able to accept the licenses:
~/Library/Android/sdk/cmdline-tools/latest/bin/sdkmanager --licenses
Before running the given command please make sure that you have done with environment variable setup on windows/mac/i/Linux/Unix for • Android SDK • SDK manager • Java • Flutter
• Execute command prompt as administrator; Run the command flutter doctor –android- licenses • press y to accept every license.; • flutter doctor -v to check if the issue was solved;
It somehow interfered with flutter! Double- check your java path entry. Go to your java environment variables and double-check your path entry. Keep one of them in the bin and remove the other. C:\Program Files\Java\jdk-11.0.8\bin C:\Program Files\Java\jdk-11.0.8
In the command line just run flutter doctor – android-licenses accept everything (by clicking y key followed by entering key). You can also give try to below code. Rename C:\Users\%username%\AppData\Local\Android\Sdk\tools folder to tool
• So, navigate to cd C:\Users\%username%\AppData\Local\Androi d\Sdk\tool\bin in cmd • After that run SDK manager –update – verbose, will create a new folder tools • Run flutter doctor –android-licenses
• Then Accept the android licenses by clicking y • To check flutter doctor if the issue was solved:
Conclusion: Thanks for Reading! So, in this article, we have been through how to Solve “You have not accepted the license agreements” In Flutter. Do let us know your feedback/comments on the same.
Conclusion: Flutter Agency is the best Flutter App development company dedicated to Flutter Technology and Flutter Developers. The portal is full of cool resources from Flutter like Flutter Widget Guide, Flutter Projects, Code libs and etc. So, contact us for your next project. Article Source: https://flutteragency.com/have-not- accepted-the-license/