Skip to content

Bug: Error while evaluating property 'lineEndingsPolicy' Spotless JVM-local cache is stale. #2025

@eye2web

Description

@eye2web
  • Gradle 8.5
  • Spotless 6.25.0
  • Windows 10 enterprise

spotless.conventions.gradle.kts

spotless {
    java {
        lineEndings = LineEnding.UNIX
        importOrder("\\#java", "\\#javax", "\\#org", "\\#", "java", "javax", "org")
        target("src/*/java/**/*.java")
        removeUnusedImports()
    }
}
* What went wrong:
Execution failed for task ':project:spotlessJava'.
> Error while evaluating property 'lineEndingsPolicy' of task ':x:spotlessJava'.
   > Spotless JVM-local cache is stale. Regenerate the cache with
       rmdir /q /s .gradle/configuration-cache
     To make this workaround obsolete, please upvote https://github.com/diffplug/spotless/issues/987

Reproduce:

  • Run ./gradlew build from umbrella includeBuilds project. (Generates the config cache)
  • Run ./gradlew --stop Stop running deamons
  • Run ./gradlew build from umbrella includeBuilds project. (Fails)

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