I have followed the steps here to create asset packs for an Android app, except that at step 8 I am receiving the following error:
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 :installtime_assetpack.
Required by:
project :app
> Project :app declares a dependency from configuration 'assetPackFiles' to configuration 'packElements' which is not declared in the descriptor for project :installtime_assetpack.
Gradle is reporting version 6.5. Has something changed that I need to add something else?
I was going to delete this question, however I figured someone might make the same bone-head error as I did, which was to have the wrong folder name for one of the assets, i.e. I had installtime_asset_pack when it should have been installtime_assetpack
If you still have same issue just try to rename your gradle.build (in folder of your assetpack) to build.gradle - it seems stupid but it helped me.
Also you can take a look to a similar file in the \Intermediate\Android\gradle\assetpacks\install-time\obbassets, and see what the name of that gradle file.
Related
We have simple composite gradle build with android project and a library project. We are getting the following error from the build
> Task :kds-android-studio:lintAnalyzeDebug FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':kds-android-studio:lintAnalyzeDebug'.
> unable to find project exploded aar for /Users/dean/workspace/tray/monorepo/android/libraries/tray-lib-android-studio :
In the build file, we have this line to pull in the artifact(per composite builds)
implementation 'com.tray.android.lib:tray-lib-android-studio'
In the settings.gradle file, we have this(per composite builds)
includeBuild '../../libraries/tray-lib-android-studio'
I have no idea what an aar file is. Any direction on debugging this further would be great? (I am mostly guessing right now and google doesn't seem to have any results on lintAnalyzeDebug and "unable to find project exploded aar".
I see an aar file fro debug and release in the tray-lib-android-studio project. Where is the main gradle project searching for 'exploded aar' and I wonder if I can just hack a target before the one that fails to explode the library aar in a good location to get this passing?
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?
I have just added react-native-firebase/firestore v6.2.0 to my React Native app. It was previously building fine whilst using the auth and messaging modules.
Now when I build the app I get the error:
> Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
> Could not find com.google.firebase:firebase-bom:21.3.0.
Searched in the following locations:
...
Required by:
project :app > project :#react-native-firebase_messaging
project :app > project :#react-native-firebase_app
project :app > project :#react-native-firebase_auth
I'm not sure what this file is or why it would have been removed.
Any help much appreciated!
After some tracking I noticed that com.google.firebase:firebase-bom:21.3.0 is missing in the
Maven repositories
Which makes me believe it never existed. After some tracking in the react-native-firebase files I noticed that tag v6.1.0 has com.google.firebase:firebase-bom:21.1.0 for some packages except for firestore, which has com.google.firebase:firebase-bom:21.3.0. And this is repeated for v6.2.0
So... yeah, It may have been problem updating the dependencies. I may upload an issue to address this.
My solution was to use version v6.0.3
You can manually edit the following file in your local node_modules: https://github.com/invertase/react-native-firebase/blob/v6.1.0/packages/firestore/android/build.gradle
My gradle settings are thus :
I have tried degrading the gradle build tool version to 2.3.2, have tried with both offline checked and unchecked and with both the default gradle wrapper and my local gradle installation. Nothing seems to work. The make on project runs successfully but deploying it fails with the following error (detailed):
Error:Gradle: A problem occurred configuring root project 'Project_Name'.
Could not resolve all dependencies for configuration ':classpath'.
Could not resolve com.android.tools.build:gradle:2.3.3.
Required by:
project :
No cached version of com.android.tools.build:gradle:2.3.3 available for offline mode.
Could not resolve commons-logging:commons-logging:1.1.1.
Required by:
project : > com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2 > org.codehaus.groovy.modules.http-builder:http-builder:0.7.2 > org.apache.httpcomponents:httpclient:4.2.1
project : > com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2 > org.codehaus.groovy.modules.http-builder:http-builder:0.7.2 > net.sf.json-lib:json-lib:2.3
project : > com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2 > org.codehaus.groovy.modules.http-builder:http-builder:0.7.2 > net.sf.json-lib:json-lib:2.3 > commons-beanutils:commons-beanutils:1.8.0
No cached version of commons-logging:commons-logging:1.1.1 available for offline mode.
Surprisingly, it deployed successfully the last time, which must have been a couple of weeks back. I did not do any configuration changes neither any updates to the Android Studio or related components. So I have no idea why this error has appeared out of the blue while deployment.
Edit 1: I have to mention that even though such questions exist on SO, none of the solutions mentioned there solved this issue. They were all suggesting disabling offline work, but it was never enabled in the first place in my project.
Edit 2 : Adding the gradle files:
Project gradle file:
App module gradle file:
App module gradle file
Sounds like a transitive dependency issue. First are you targeting Oreo? if so, make sure you include the new google/maven repo pointer in your build.gradle file.
If not or if you have already done this, then try including the commons-logging 1.1.1 file that the bintry-plugin is requiring.
Are any of the dependencies listed in your yellow yours? Could just be a transitive dependency missing that needs either included or excluded.
Also make sure you have the correct gradle repos setup for pulling the 2.3.2. Can you share your project gradle file as well as your gradle.properties and your settings.gradle and any other applicable gradle file that you are using. I'm sure we can get you up and going again.
Resolving dependencies is a pain, but you can usually hunt it down if you do a bash gradlew assembleRelease --debug and see where/how the issue shows itself first.
I am new to Android Studio IDE. I have created a sample project using Android Studio and when I tried to build it, it comes with the following error.
Error:A problem occurred configuring root project 'SampleApp".
> Could not resolve all dependencies for configuration ':classpath'.
> Could not download artifact 'org.bouncycastle:bcprov-jdk15on:1.48:bcprov-jdk15on.jar': No
cached version available for offline mode
Can anyone please figure out what I did wrong.
It needs to download that library in order to do your build, but you've (perhaps inadvertantly) put Android Studio into offline mode. To fix it, go to Preferences > Gradle and ensure that the "Offline work" checkbox is not checked.
I think you should add following code at the top level of your build.gradle:
repositories {
mavenCentral()}
You might also need to try with --refresh-dependencies.
You can take more help from this here.