gradle-resolution-rules-plugin icon indicating copy to clipboard operation
gradle-resolution-rules-plugin copied to clipboard

Gradle 4.10.2 and new IMPROVED_POM_SUPPORT and gradle lint

Open remy-tiitre opened this issue 7 years ago • 0 comments

Any idea, what might be causing these kind of errors when I run autoLintGradle on a project where I use bom imports and gradle resolution rules plugin:

Resolution rules could not resolve all dependencies to align configuration ':lintExcludes':
 - org.springframework.boot:spring-boot-starter-data-jpa:null -> org.springframework.boot:spring-boot-starter-data-jpa:null - Could not find org.springframework.boot:spring-boot-starter-data-jpa:null.
Resolution rules could not resolve all dependencies to align configuration ':lintExcludes':
 - com.jayway.jsonpath:json-path:null -> com.jayway.jsonpath:json-path:null - Could not find com.jayway.jsonpath:json-path:null.

I have added enableFeaturePreview('IMPROVED_POM_SUPPORT') to settings.gradle

And to give some context I have outline some configuration from my build.gradle file. Its a lot more complicated offcouse as we are using init scripts and theres a lot more going on. And its multi project setup as well.

plugins {
    id 'java'
    id 'nebula.resolution-rules' version '7.0.4'
    id 'nebula.lint' version '9.3.2'
    id 'org.springframework.boot' version '2.0.6.RELEASE'
}

gradleLint {
    rules = ['unused-exclude-by-dep']
}

dependencies {
    resolutionRules 'com.netflix.nebula:gradle-resolution-rules:latest.release'
    compile org.springframework.boot.gradle.plugin.SpringBootPlugin.BOM_COORDINATES
    implementation('org.springframework.boot:spring-boot-starter-data-jpa') {
        exclude group: 'org.hibernate', module: 'hibernate-entitymanager'
    }
}

Unfortunately I'm not able to pin it down to java source code or some transitive dependency that causes this. Using just this clean setup I provided here works fine. Maybe you have had similar issues or have suggestions how to debug it

remy-tiitre avatar Oct 30 '18 15:10 remy-tiitre