I have problem with building my project in android studio.
I cant do ./gradlew clean and ./gradlew build from terminal and all is completed successful.
When im trying to click "Rebuild project" in android studio, im getting error:
org.gradle.tooling.GradleConnectionException: Could not execute build using Gradle distribution 'http://services.gradle.org/distributions/gradle-1.6-bin.zip'.: Could not execute build using Gradle distribution 'http://services.gradle.org/distributions/gradle-1.6-bin.zip'.
I think it happened, when I updated my Android Studio. Can you help me solve this problem?
Im using Kubuntu 13.10.
I needed to update Gradle to 1.8 and change it in project gradle Wrapper.
Related
I was creating APK for my flutter project so I followed the below steps to generate a signed APK
Tools -> Flutter -> Open for editing in android studio
Then opened the model in a new window
I got the Gradle sync failed error, After my further investigation I run the command gradlew --warning-mode all in the terminal & I got the below message from gradle
The AbstractArchiveTask.destinationDir property has been deprecated. This is scheduled to be removed in Gradle 7.0. Please use the destinationDirectory property instead.
Since I am new to flutter & always scared of Gradle failing, I am not sure how to fix this issue & set the destination directory
Or if you know how to create APK from the flutter project do let me know if I am doing anything wrong to generate APK
Gradle sync failed error is not any error in flutter.
to build apk in flutter first of all you run flutter clean command
then run flutter pub get command
after then you run flutter build apk command to build apk
also if you use Android Studio then you can build apk without command using
in Android Studio in top menu Build => Flutter => Build APK and click on Build APK
it will make apk for you
I am currently working on a android application which has CI/CD implementation. Everything was working as expected for gradle version 2.0.1. I was able to run ./gradlew clean build command but recently I have upgraded Application to gradle version 3.4.1.
I am able to run the application on Android Device and Android Emulator.
However When I am running the same command in terminal build process is getting haulted while doing lint analysis.
I was using android studio version 3.0.1 with gradle version 2.0.1. Application has CI implementation using Jenkins. project was building fine with the configurations when built using ./gradlew clean build.
Recently I have upgraded Android studio to version 3.4.1 and also gradle to 3.4.1 and migrated project from support library to AndroidX.
I am able to upgrade project with some minor warnings. Also able to ran project on Mobile device and on emulator.
However when I try to build project using gradle command then progress is getting stuck while performing lint and goes in infinite loop.
I kept it running for 18 hrs and it kept running.
./gradlew clean build
Project should build fine but somehow lint is not getting completed. Is there any way I can resolve this issue or I can skip lint checks while building the code.
Whenever I import a project to Android Studio, the gradle sync is initiated automatically and I get build failure errors. Because of this I am unable to traverse the code and not able to debug the code. Is there anyway to use Android Studio for just traversing the code flow and not building the code with gradle?
You can call ./gradlew --stop in a Terminal and it will kill all gradle processes
I'm trying to build Terminal Emulator for Android. I'm running Android Studio 1.4 in Kubuntu 15.04. I also tried building it in Ubuntu 14.04 LTS with the same results. The project requires the latest Android NDK, SDK 22, and SDK 11 which I've downloaded and configured in Android Studio. My system gradle version is 2.8, and Android Studio has downloaded some other versions internally. I'm using jdk1.8.0_65, which is set to JAVA_HOME and configured in Android Studio. I've built several other projects with my configured Android Studio and only seem to have a problem with this project. I need to use this project as a base for an app I'm developing.
I end up with same error, posted below, no matter what route I take to fix it in Android Studio. This is generally what I've done to try and get the project to work. I open up the project unmodified in Android Studio. I click Build >> Rebuild Project. I get an error telling me ndk implementation is deprecated. I add a file gradle.properties to the root directory of the project with the line android.useDeprecatedNdk=true and rebuild. It gives me an error: Task 'generateDebugTestSources' not found in project. I execute Sync Project With Gradle Files to resolve it. Then I end up with the following error and can't get past it.
Gradle 'Android-Terminal-Emulator-master' project refresh failed
Error:exception during working with external system:
or
Gradle sync failed: exception during working with external system:
Consult IDE log for more details (Help | Show Log)
idea.log
Things I've done to try and get the project to build:
Modify all of the project's build.gradle files to use the experimental plugin
Use different versions of Android Studio
Switch from openjdk to Oracle's jdk
Upgrade gradle to the latest version
Set gradle to default wrapper (default) and also set gradle to different versions
invalidate cache, remove ~/.gradle, and rebuild project
Make sure PATH includes the gradle and jdk bin directories and is in ~/.bashrc, ~/.profile, and ~/.zshrc
remove proguard from libtermexec library
reboot computer
I should note that the project builds without issue on the command line. I'd really like to get the project to build in Android Studio for development.
Install Arch and run Android Studio there.
I decided to try building Terminal Emulator on my Arch server, so I installed a xfce (Desktop Environment) and Android-Studio through pacman. I followed the same general path to get things setup, and the app built without issue.
The idea log Android Studio generated for the failed build on Windows and Ubuntu didn't point to any clear problem, even with --stacktrace enabled with gradle. I'm not going to waste my time figuring out why gradle doesn't want to build apps in Ubuntu or Windows.
I've got a problem building inside Android Studio.
Error I get is:
org.gradle.tooling.GradleConnectionException: Could not execute build using Gradle distribution 'http://services.gradle.org/distributions/gradle-1.7-bin.zip'.: Could not execute build using Gradle distribution 'http://services.gradle.org/distributions/gradle-1.7-bin.zip'.
It works just fine to build if I execute gradlew compileDebug from command line but not inside Android Studio.
I've got this error once before, at that time it worked after restarting Android Studio, but not any more.
I've tried to set GRADLE_HOME as suggested here Gradle home and using a local distribution. I've also tried to remove the .gradle cache in C:\Users\XXX folder as suggested at other pages and "Invalidate caches/Restart" inside Android Studio.
It was working yesterday and I haven't changed the build files or added any new files.
What can be wrong? Please help!