Skip to content

Scoverage plugin is not usable in multi-project parallel builds with Gradle 6.7+ #150

Open
@netvl

Description

@netvl

Please check this Gradle issue: gradle/gradle#15730

In short, if org.gradle.parallel=true project property is set, using the Scoverage plugin in a multi-project build with compilation dependencies between projects will result in an exception:

A problem occurred configuring project ':first'.
> Could not determine the dependencies of task ':second:compileJava'.
   > Current thread does not hold the state lock for project :second

This project reproduces the error.

The cause of the error is apparently this portion of the plugin's logic:

def originalCompilationDependencies = recursiveDependenciesOf(compileTask).findAll {
it instanceof ScalaCompile
}

which causes some internal invariants in Gradle to fail due to cross-project access.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions