I am beginner of ionic mobile development and now I am setting CI for my mobile application using Jenkins (on localhost). I am facing an error that I am unable to resolve for many days. ionic compiles successfully but at the last at the time of android build preparation it fails and gives error I mentioned below.
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all files for configuration ':classpath'.
> Could not resolve com.android.tools.build:gradle:3.0.0.
Required by:
project :
> Could not resolve com.android.tools.build:gradle:3.0.0.
> Could not get resource 'https://jcenter.bintray.com/com/android/tools/build/gradle/3.0.0/gradle-3.0.0.pom'.
> Could not GET 'https://jcenter.bintray.com/com/android/tools/build/gradle/3.0.0/gradle-3.0.0.pom'.
> corphttpsproxyhost.yourdomain: Name or service not known
> Could not resolve com.android.tools.build:gradle:3.0.0.
> Could not get resource 'https://maven.google.com/com/android/tools/build/gradle/3.0.0/gradle-3.0.0.pom'.
> Could not GET 'https://maven.google.com/com/android/tools/build/gradle/3.0.0/gradle-3.0.0.pom'.
> corphttpsproxyhost.yourdomain
Please let me know where I am committing mistake, or is there any other dependency issue.
Thanks
I think you did not add gradle 3.0.0
You can do this by going to “Configure System” (Jenkins 1.x) or to “Global Tool Configuration” (Jenkins 2.x). From the home page navigate to:
Manage Jenkins -> Configure System (Jenkins 1.x)
Manage Jenkins -> Global Tool Configuration (Jenkins 2.x)
Scroll down a little bit and you should encounter a small section for gradle with a single button labeled “Gradle installations…”. Click on that button to expand the configuration panel.
The gradle configuration panel will ask for a few parameters. Here you can set the tool to a static path, or let Jenkins handle the installation for you. We recommend using “Install automatically” for ease of use. Below is an example of an automatic installation of gradle 3.0.0
than you have to select this gradle version from your project configration.
in bbuild tab
add Invoke Gradle script
Invoke Gradle
X Gradle Version 3.0.0
than build it it may help you
Related
I have followed this guide to implement the GooglePAD plugin in UE 4.27, but I'm met with the following error when I try to package the project for the second time (first time generates the asset packs):
FAILURE: Build failed with an exception.
* What went wrong:
Could not determine the dependencies of task ':app:assetPackDebugPreBundleTask'.
> Could not resolve all task dependencies for configuration ':app:assetPackFiles'.
> Could not resolve project :assetpacks:on-demand:OnDemandPack.
Required by:
project :app
> Project :app declares a dependency from configuration 'assetPackFiles' to configuration 'packElements' which is not declared in the descriptor for project :assetpacks:on-demand:OnDemandPack.
I see that there is a similar question here, but their solution doesn't seem to apply to me since I'm certain my folders are properly named. This happens with all 3 of my on-demand packs. The build.gradle file inside the asset pack folders is exactly the same as the one included in the guide, though I have tried just writing the pack names as shown here to no avail.
What should I do to build successfully with this plugin?
A problem occurred configuring root project 'My Application'.
Could not resolve all artifacts for configuration ':classpath'.
Could not resolve com.android.tools.build:gradle:3.6.2.
Required by:
project :
No cached version of com.android.tools.build:gradle:3.6.2 available for offline mode.
No cached version of com.android.tools.build:gradle:3.6.2 available for offline mode.
This is my error and I don't know how to solve this please help me to solve this
In Android Studio select
View > Tool Windows > Gradle
from the menu bar.Here On the top of the Gradle window ,click on Toggle Offline Mode button in the Gradle window.
An android app fails to build and run and displays this error message.
Task 'extractApksForDebug' not found in project ':app'.
When I tried to clean and build again, this error comes
Task 'bundleDebug' is ambiguous in project ':app'. Candidates are: 'bundleDebugAndroidTestResources', 'bundleDebugResources'.
How can I find the error and correct that?
Go to Help > Check for Updates.
Update all.
This will resolve the issue.
This one works for me.
On right pane of android studio click on Gradle > Right click on project > Refresh Gradle dependencies.
I am new to Android Studio. But after updating my Android Studio to the latest version everything works fine, but when I decide to run the app I get this error:
(Error:Execution failed for task ':app:compileDebugJavaWithJavac'.
java.io.FileNotFoundException: C:\Users\collinluvpc.gradle\caches\2.14.1\classAnalysis\cache.properties (The system cannot find the file specified))
I have tried to invalidate cache and restart but nothing seems to work. Please help.
At first Upgrade SDK Manager .
(Error:Execution failed for task ':app:compileDebugJavaWithJavac'. java.io.FileNotFoundException: C:\Users\collinluvpc.gradle\caches\2.14.1\classAnalysis\cache.properties (The system cannot find the file specified))
This exception is thrown during a failed attempt to open the file denoted by a specified pathname.
What is your classpath ??
You can use
compile 'com.google.android.gms:play-services:current_version'
& Use this
classpath 'com.android.tools.build:gradle:current_version'
Then Clean-Rebuild Your Project .
Go to File > Settings > Build Tools > Gradle > Configure "Gradle User Home to" -> user/.android/.gradle
I'm trying to build my app in Cordova 5.4 using cordova run android. I'm getting this:
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_debugCompile'.
> Could not find any version that matches com.android.support:support-v4:+.
Searched in the following locations:
https://repo1.maven.org/maven2/com/android/support/support-v4/maven-metadata.xml
https://repo1.maven.org/maven2/com/android/support/support-v4/
Required by:
:android:unspecified
I can't seem to track this one down. Look familiar?
Sorry, if this should be a comment but I don't have enough points yet to do so.
Please try to install Android Support Repository in the Android SDK Manager.
Then check whether this works
cordova build android --verbose
If it's successful,
cordova run android --verbose
Source:
https://github.com/AzureAD/azure-activedirectory-library-for-cordova/issues/6
Check for android-support-v4.jar in your project build path.