Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

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?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
988 views
Welcome To Ask or Share your Answers For Others

1 Answer

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


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...