I'm trying to add the following dependency:
compile group: 'com.cedarsoft.commons', name:'test-utils', version:'5.0.9'
Gradle downloads a couple of jars and then I'm getting the following error:
POM relocation to an other version number is not fully supported in Gradle : xml-apis#xml-apis;2.0.2 relocated to xml-apis#xml-apis;1.0.b2.
Please update your dependency to directly use the correct version 'xml-apis#xml-apis;1.0.b2'.
Resolution will only pick dependencies of the relocated element. Artifacts and other metadata will be ignored.
Any ideas why and how to solve this issue?
Generally, you can refresh dependencies in your cache with the command line option --refresh-dependencies. You can also delete the cached files under ~/. gradle/caches . With the next build Gradle would attempt to download them again.
Gradle declares dependencies on JAR files inside your project's module_name /libs/ directory (because Gradle reads paths relative to the build.gradle file). This declares a dependency on version 12.3 of the "app-magic" library, inside the "com.example.android" namespace group.
configurations.all {
resolutionStrategy {
force 'xml-apis:xml-apis:1.4.01'
}
}
Or use 1.0.b2. The issue is that there POM of xml-apis redirects for 2.0.2 (as khmarbaise wrote) to the same group and artefact, only version being 1.0.b2, which somehow fools Gradle (or underlying Ivy) resolution mechanism.
The credit goes to Mark Petrovic Gradle Forum
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With