Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ExcludeTransitiveDependenciesFilter fails with error: 'developmentOnly' not found. #254

Open
amoghsg opened this issue Jan 6, 2023 · 1 comment

Comments

@amoghsg
Copy link

amoghsg commented Jan 6, 2023

Using Gradle 6.7.1
I was successfully able to execute vanilla version of ./gradlew generateLicenseReport.

But on including

licenseReport {
    filters = [new ExcludeTransitiveDependenciesFilter()]
}

in build.gradle

It fails with the following error:

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.

What went wrong:
Execution failed for task ':xyz:generateLicenseReport'.

Configuration with name 'developmentOnly' not found.

==============================================================================

2: Task failed with an exception.

What went wrong:
Execution failed for task ':generateLicenseReport'.

Configuration with name 'developmentOnly' not found.

The relevant parts of my build.gradle:

plugins {
    id 'com.github.jk1.dependency-license-report' version '1.17' apply false
}

allprojects {
    repositories {
        maven {
            url "https://plugins.gradle.org/m2/"
        }
        maven {
            url "https://maven.google.com"
        }
        maven {
            url "https://packages.confluent.io/maven"
        }
        mavenCentral()
    }

    if (!project.name.equals("app")) {
        apply plugin: 'kotlin'
    }

    apply plugin: 'com.github.jk1.dependency-license-report'

    compileKotlin {
        kotlinOptions.jvmTarget = JavaVersion.VERSION_1_8.toString()
    }

    compileTestKotlin {
        kotlinOptions.jvmTarget = JavaVersion.VERSION_1_8.toString()
    }

    licenseReport {
        renderers = [new CsvReportRenderer()]
        filters = [new ExcludeTransitiveDependenciesFilter()]
    }
@plebcity
Copy link

@amoghsg Have you managed to find a workaround for this problem?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants