Closed ashLikun closed 2 years ago
I have the same problem when trying to publish my own android library to jitpack. It was working fine just yesterday. But now it suddenly give me an error message:
Failed to install the following Android SDK packages as some licences have not been accepted.
build-tools;28.0.3 Android SDK Build-Tools 28.0.3
platforms;android-28 Android SDK Platform 28
I rebuilt my library and updated the version several times but still no use. Is it something wrong with the jitpack server?
Seeing as there are three other issues right before this one about the same problem, I'd say it's probably something up with the build servers.
https://github.com/jitpack/jitpack.io/issues/3686 https://github.com/jitpack/jitpack.io/issues/3685 https://github.com/jitpack/jitpack.io/issues/3684
I had the same problem.
I have same issue!:|
`* What went wrong: A problem occurred configuring project ':app'.
Failed to install the following Android SDK packages as some licences have not been accepted. build-tools;28.0.3 Android SDK Build-Tools 28.0.3 platforms;android-28 Android SDK Platform 28 `
I had the same problem too!
anyone resolve the problem?
The same with me
Anyone resolve this issue?
@avshvetsov I have managed to resolve this by "hacking" around the script by adding command to accept the license. Please refer to this commit that have resolved my build. This is the log that proves that it has built successfully.
Basically, you add one line of code at your project file graldew
with the following code
yes | $ANDROID_HOME/tools/bin/sdkmanager "build-tools;28.0.3"
@avshvetsov
Thanks!!!
yes | $ANDROID_HOME/tools/bin/sdkmanager "platforms;android-28"
yes | $ANDROID_HOME/tools/bin/sdkmanager "build-tools;27.0.3"
worked for me on gradlew
I have a safer solution. First of all, put this in jitpack.yml and not in gradlew -- so it will only affect JitPack and not others that happen to run your build. Second, instead of explicitly installing the components, just tell Android you accepted the license.
Copy this gist to some server you control (GitHub pages is a great option and so is a Gist): https://gist.github.com/noamtamim/b04ef67239d2b43638aa5a9a024a1937
Create jitpack.yml (if you don't have one already) in the root of the repo:
before_install:
- curl URL_OF_THE_FILE | sh
Example:
before_install:
- curl https://gist.githubusercontent.com/noamtamim/b04ef67239d2b43638aa5a9a024a1937/raw/56f1a38dd88a3774b71a063822444f3961d61873/android-sdk-license.sh | sh
Make sure the URL is to the RAW file. But please copy this to your own account/gist/server. Every time there's an updated license, update this file with the new license hash. Legally if you run this script (or your own version of it), it means you accepted the license. See here for more info: https://developer.android.com/studio/intro/update#download-with-gradle
Hi all,
Should be fixed now. Thanks for the workarounds!
Hi, seems not fixed yet
Build starting... Start: Mon Jan 21 13:36:13 UTC 2019 7ad8e0ad4e6c
...
Failed to install the following Android SDK packages as some licences have not been accepted. build-tools;28.0.3 Android SDK Build-Tools 28.0.3 platforms;android-28 Android SDK Platform 28
Anyway thanks for addressing this issue!
seems to be fixed already, thanks :)
@jitpack-io not all problems are resolved: https://jitpack.io/com/github/avshvetsov/FastScroll/6ca6585d5a/build.log
Can you help?
It is not working for me either https://jitpack.io/com/github/goui/testlib/0.1.4/build.log
I have added the 2 lines at the end of my gradlew. Thing is, even without those lines the ./gradlew install was working for me locally.
I think you might have a problem with your CI not accepting the licenses.
@jitpack-io https://jitpack.io/com/github/silencedut/diffadapter/1.2.0/build.log still not be resolved in my project
@SilenceDut Rebuilt v1.2.0
Still not working for me :/ https://jitpack.io/com/github/inmobly/boltplay/1.0.18/build.log
Still not working for me :/ https://jitpack.io/com/github/inmobly/boltplay/1.0.18/build.log
@oahmedazab did you try my workaround? It's very easy to implement. See https://github.com/jitpack/jitpack.io/issues/3687#issuecomment-455901608.
Still not working for me ,but when i restart android studio it(the bug) disappear!
Small clarification on how this works: JitPack will try to read your build.gradle to find SDK and build-tools version. It will then install those versions. If you are using properties in your build.gradle, like this:
compileSdkVersion rootProject.ext.android["compileSdkVersion"]
buildToolsVersion rootProject.ext.android["buildToolsVersion"]
then JitPack is unable to detect those versions (yet).
For now we recommend using versions directly in build.gradle like this:
compileSdkVersion "28"
buildToolsVersion "28.0.3"
Nope the morons who decided to remove the --licenses option have no clue what they are doing. I am still getting that same error myself. It has to do with 28.0.3
I can't complete this bloody project now. Thanks android!
Starting a Gradle Daemon, 2 incompatible and 1 stopped Daemons could not be reused, use --status for details
Configure project :app Checking the license for package Android SDK Build-Tools 28.0.3 in E:\android-sdk\licenses Warning: License for package Android SDK Build-Tools 28.0.3 not accepted. Checking the license for package Android SDK Platform 27 in E:\android-sdk\licenses Warning: License for package Android SDK Platform 27 not accepted.
FAILURE: Build failed with an exception.
What went wrong: A problem occurred configuring project ':app'.
Failed to install the following Android SDK packages as some licences have not been accepted. platforms;android-27 Android SDK Platform 27 build-tools;28.0.3 Android SDK Build-Tools 28.0.3 To build this project, accept the SDK license agreements and install the missing components using the Android Studio SDK Manager. Alternatively, to transfer the license agreements from one workstation to another, see http://d.android.com/r/studio-ui/export-licenses.html
Using Android SDK: E:\android-sdk
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 11s
@Sangra69 Even though it seems to be working according to user feedback (I'm a JitPack user, not staff), have you tried the workaround I suggested here? https://github.com/jitpack/jitpack.io/issues/3687#issuecomment-455901608
Hi,I have the same problem, and I solved this problem by this way,my system is window10,and IDE is Android studio.
Still not working for me ,but when i restart android studio it(the bug) disappear!
This -- interestingly -- fixed my problem too...
Greetings! Run the following command on the Terminal as administrator
flutter doctor --android-licenses
It should count the number of licenses that you have not accepted and then ask you for a review press Y and then accept all the licenses you need.
I hope it helps, have a nice happy coding hours! Cheers!!!
I downloaded build tools and SDK using Android Studio.
Hope this helps for anyone.
Small clarification on how this works: JitPack will try to read your build.gradle to find SDK and build-tools version. It will then install those versions. If you are using properties in your build.gradle, like this:
compileSdkVersion rootProject.ext.android["compileSdkVersion"] buildToolsVersion rootProject.ext.android["buildToolsVersion"]
then JitPack is unable to detect those versions (yet).
For now we recommend using versions directly in build.gradle like this:
compileSdkVersion "28" buildToolsVersion "28.0.3"
This Solved My Problem , Thank You
Fixed when I changed the bitbucket-pipelines.yml file. I've added a second licence value, because I had only one. You can check the values on your local machine in $ANDROID_HOME/licenses
folder.
The line I changed.
- echo -e "\nd56f5187479451eabf01fb78af6dfcb131a6481e \n24333f8a63b6825ea9c5514f83c2829b004d1fee" > "$ANDROID_HOME/licenses/android-sdk-license"
Yml file changes.
Licence files on the local machine.
Just open SDK Manager in Android Studio and install SDK version 28(Android Pie)
locate tools\bin in your cmd then type sdkmanager --licenses. if it says that all licenses are accepted but then youre still encountering the issue. try to restart your computer and rebuild again.
locate tools\bin in your cmd then type sdkmanager --licenses. if it says that all licenses are accepted but then youre still encountering the issue. try to restart your computer and rebuild again.
$ANDROID_HOME/tools/bin/sdkmanager --licenses that is work for me
For me it was just that my project was on an external hard drive and forgot to plug it in. So check it if thats the case!
Hi,I have the same problem, and I solved this problem by this way,my system is window10,and IDE is Android studio.
thank you, this actually works
Hey!!!
Just open terminal or git bash and head over to your android studio directory. Command Terminal is recommended for Windows users.
For windows users:
cd C:\Users\{USERNAME}\AppData\Local\Android\Sdk\tools\bin
and then run this to accept unaccepted licenses.
sdkmanager.bat --licenses
and then just review and accept them by typing 'y' and hit enter till its done..
Reference:
@aveenashmandhwani Worked like a charm! Thanks a lot for sharing. (on macOS just open /usr/local/share/android-sdk
on your terminal)
run command in cmd: flutter doctor --android-licenses
Just install tools as per the attached image in AndroidSDK >> SDK Tools it will work. For me "Google Play Licensing Library" was missing.
~/Library/Android/sdk/tools/bin ./sdkmanager --licenses
just this
just install ur android studio update...
all what you need is to install them manually by the sdk-manager tool,
anyone can assist me on this? i have no clue what sdkmanager is. im trying to call "cordova build android" and this error message popped. how do i solve this given that i have android studio already
locate tools\bin in your cmd then type sdkmanager --licenses. if it says that all licenses are accepted but then youre still encountering the issue. try to restart your computer and rebuild again.
$ANDROID_HOME/tools/bin/sdkmanager --licenses that is work for me
That is work for me, Tks!
anyone can assist me on this? i have no clue what sdkmanager is. im trying to call "cordova build android" and this error message popped. how do i solve this given that i have android studio already
Install Android Studio, on Welcome to Android Studio Screen on the right bottom you will see Configure, there choose SDK Manager ---> Appearance & Behavior --> System Settings --> Android SDK install Android version you gonna use maybe from 8.0 to latest..
This did the trick for me with Ionic 4 Cordova
run the flutter console.Use the command "flutter doctor" and you gonna find the problem.This work for me.
https://github.com/jitpack/jitpack.io/issues/3684 closed for me.
Android Studio: Appearance & Behavior/System Settings/Android sdk/SDK Update Sites check checkbox Force https://... sources to be fetched using http:// try run again and don't forget to check any other third party you need.
You have just to install android sdk 27 TOOLS -> SDK MANAGER -> android 8.1 with api level 27 -> apply build a second time, It will works !!
In Android Studio 3.6 or later, you need to manually add the old version of the Android SDK Tools for Flutter to work. To do this: Open the Android Studio SDK Manager In the Android SDK tab, uncheck Hide Obsolete Packages Check Android SDK Tools (Obsolete) and install.
A problem occurred evaluating script.
Using Android SDK: /opt/android-sdk-linux