Skip to content

Update Gradle to v9#153

Merged
stewemetal merged 3 commits intomainfrom
renovate/gradle-9.x
Feb 25, 2026
Merged

Update Gradle to v9#153
stewemetal merged 3 commits intomainfrom
renovate/gradle-9.x

Conversation

@renovate
Copy link
Contributor

@renovate renovate bot commented Jan 26, 2026

This PR contains the following updates:

Package Update Change
gradle (source) major 8.14.49.3.1

Warning

Some dependencies could not be looked up. Check the Dependency Dashboard for more information.


Release Notes

gradle/gradle (gradle)

v9.3.1: 9.3.1

Compare Source

This is a patch release for 9.3.0. We recommend using 9.3.1 instead of 9.3.0.

The following issues were resolved:

Read the Release Notes

Upgrade instructions

Switch your build to use Gradle 9.3.1 by updating your wrapper:

./gradlew wrapper --gradle-version=9.3.1 && ./gradlew wrapper

See the Gradle 9.x upgrade guide to learn about deprecations, breaking changes and other considerations when upgrading.

For Java, Groovy, Kotlin and Android compatibility, see the full compatibility notes.

Reporting problems

If you find a problem with this release, please file a bug on GitHub Issues adhering to our issue guidelines.
If you're not sure you're encountering a bug, please use the forum.

We hope you will build happiness with Gradle, and we look forward to your feedback via Twitter or on GitHub.

v9.3.0

Compare Source

v9.2.1: 9.2.1

Compare Source

The Gradle team is excited to announce Gradle 9.2.1.

Here are the highlights of this release:

  • Windows ARM support
  • Improved publishing APIs
  • Better guidance for dependency verification failures

Read the Release Notes

We would like to thank the following community members for their contributions to this release of Gradle:
Adam,
Björn Kautler,
hasunzo,
HYEON,
Hyunjoon Park,
HYUNJUN SON,
Jendrik Johannes,
Kirill Gavrilov,
Madalin Valceleanu,
Martin Bonnin,
Matthew Haughton,
Mikhail Polivakha,
Na Minhyeok,
Philip Wedemann,
Philipp Schneider,
Róbert Papp,
Simon Marquis,
TheGoesen,
Vincent Potucek,
Xin Wang.

Upgrade instructions

Switch your build to use Gradle 9.2.1 by updating your wrapper:

./gradlew wrapper --gradle-version=9.2.1 && ./gradlew wrapper

See the Gradle 9.x upgrade guide to learn about deprecations, breaking changes and other considerations when upgrading.

For Java, Groovy, Kotlin and Android compatibility, see the full compatibility notes.

Reporting problems

If you find a problem with this release, please file a bug on GitHub Issues adhering to our issue guidelines.
If you're not sure you're encountering a bug, please use the forum.

We hope you will build happiness with Gradle, and we look forward to your feedback via Twitter or on GitHub.

v9.2.0

Compare Source

v9.1.0: 9.1.0

Compare Source

The Gradle team is excited to announce Gradle 9.1.0.

Here are the highlights of this release:

  • Full Java 25 support
  • Native task graph visualization
  • Enhanced console output

Read the Release Notes

We would like to thank the following community members for their contributions to this release of Gradle:
Eng Zer Jun,
EunHyunsu,
Gaëtan Muller,
HeeChul Yang,
Jendrik Johannes,
Johnny Lim,
Junho Lee,
Kirill Gavrilov,
Matthew Haughton,
Na Minhyeok,
Philip Wedemann,
Philipp Schneider,
Pradyumna C,
r-a-sattarov,
Ryszard Perkowski,
Sebastian Schuberth,
SebastianHeil,
Staffan Al-Kadhimi,
winfriedgerlach,
Xin Wang.

Upgrade instructions

Switch your build to use Gradle 9.1.0 by updating your wrapper:

./gradlew wrapper --gradle-version=9.1.0 && ./gradlew wrapper

See the Gradle 9.x upgrade guide to learn about deprecations, breaking changes and other considerations when upgrading.

For Java, Groovy, Kotlin and Android compatibility, see the full compatibility notes.

Reporting problems

If you find a problem with this release, please file a bug on GitHub Issues adhering to our issue guidelines.
If you're not sure you're encountering a bug, please use the forum.

We hope you will build happiness with Gradle, and we look forward to your feedback via Twitter or on GitHub.

v9.0.0: 9.0.0

Compare Source

The Gradle team is excited to announce Gradle 9.0.0.

Here are the highlights of this release:

  • Configuration Cache is the recommended execution mode
  • Gradle requires JVM 17 or higher to run
  • Build scripts use Kotlin 2.2 and Groovy 4.0
  • Improved Kotlin DSL script compilation avoidance

Read the Release Notes

We would like to thank the following community members for their contributions to this release of Gradle:
Aaron Matthis,
Adam E,
Adam S,
Björn Kautler,
Daniel Lacasse,
Eng Zer Jun,
EunHyunsu,
FlorianMichael,
Francisco Prieto,
Gaëtan Muller,
Jake Wharton,
Kengo TODA,
Kent Kaseda,
Madalin Valceleanu,
Marc Philipp,
Mark S. Lewis,
Matthew Haughton,
Mycroft Wong,
Na Minhyeok,
Nelson Osacky,
Olivier "Oli" Dagenais,
ploober,
Radai Rosenblatt,
Róbert Papp,
Sebastian Schuberth,
Victor Merkulov.

Upgrade instructions

Switch your build to use Gradle 9.0.0 by updating your wrapper:

./gradlew wrapper --gradle-version=9.0.0 && ./gradlew wrapper

See the Gradle 9.0.0 upgrade guide to learn about deprecations, breaking changes and other considerations when upgrading.

For Java, Groovy, Kotlin and Android compatibility, see the full compatibility notes.

Reporting problems

If you find a problem with this release, please file a bug on GitHub Issues adhering to our issue guidelines.
If you're not sure you're encountering a bug, please use the forum.

We hope you will build happiness with Gradle, and we look forward to your feedback via Twitter or on GitHub.


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot force-pushed the renovate/gradle-9.x branch 19 times, most recently from 6b6c087 to 7b08754 Compare January 30, 2026 13:50
@renovate renovate bot force-pushed the renovate/gradle-9.x branch 2 times, most recently from e685743 to ae9fd58 Compare February 5, 2026 20:36
@renovate renovate bot force-pushed the renovate/gradle-9.x branch 2 times, most recently from 484588e to 25b0411 Compare February 13, 2026 10:34
@renovate renovate bot force-pushed the renovate/gradle-9.x branch from 25b0411 to f167b7d Compare February 19, 2026 09:14
@stewemetal
Copy link
Owner

@claude Check what needs to be done to make this Gradle version migration work.

@claude
Copy link

claude bot commented Feb 22, 2026

Claude finished @stewemetal's task in 2m 35s —— View job


Gradle 9.x Migration Analysis

Tasks:

  • Gather context from the PR
  • Analyze current build configuration and dependency versions
  • Check CI failure logs for actual errors
  • Identify and prepare fix for the breaking change
  • Report full findings

Root Cause of Build Failure

The CI fails at build-logic/dependencychecker/src/main/java/com/stewemetal/dependencychecker/DependencyCheckerPlugin.kt:119 with:

Unresolved reference 'dependencyProject'
> Task :build-logic:dependencychecker:compileKotlin FAILED

Why: Gradle 9 removed the dependencyProject property from ProjectDependency. Additionally, the code was using the internal API class DefaultProjectDependency (from org.gradle.api.internal) which is not part of the public Gradle API.

Required Fix

In build-logic/dependencychecker/src/main/java/com/stewemetal/dependencychecker/DependencyCheckerPlugin.kt:

Replace the import:

// Before
import org.gradle.api.internal.artifacts.dependencies.DefaultProjectDependency

// After
import org.gradle.api.artifacts.ProjectDependency

Replace the dependentModules() function:

// Before
private fun Project.dependentModules(): List<Project> {
    return configurations
        .filter { it.name == "api" || it.name == "implementation" }
        .flatMap { configuration ->
            configuration.dependencies
                .filterIsInstance<DefaultProjectDependency>()
                .map { it.dependencyProject }
        }
}

// After
private fun Project.dependentModules(): List<Project> {
    return configurations
        .filter { it.name == "api" || it.name == "implementation" }
        .flatMap { configuration ->
            configuration.dependencies
                .filterIsInstance<ProjectDependency>()
                .map { project(it.path) }
        }
}

This replaces the removed internal API (DefaultProjectDependency.dependencyProject) with the public ProjectDependency interface, resolving the project via project(it.path) — the Gradle 9-compatible approach.

Note: I prepared this commit locally but cannot push to this Renovate-managed branch. Please apply the fix manually or add it as a separate commit to this branch. Fix this →


Other Compatibility Notes

The remaining dependencies look compatible with Gradle 9:

Component Version Status
AGP 8.13.2 Compatible with Gradle 9
Kotlin 2.3.10 Compatible with Gradle 9
KSP 2.3.6 Compatible (tied to Kotlin 2.3.x)
Detekt 1.23.8 Compatible
Koin 4.1.1 Compatible

Minor deprecation warning (non-blocking): The gradle-home-cache-cleanup input in the CI workflow has been superseded by cache-cleanup in gradle/actions@v5. This is a warning only, not a build failure.

@stewemetal
Copy link
Owner

@claude the unit_test workflow is failing, check for a solution. The solution migh just be setting the 'failOnNoDiscoveredTests' property to false, but check anyway.

@claude
Copy link

claude bot commented Feb 25, 2026

Claude finished @stewemetal's task in 1m 57s —— View job


Investigating unit_test workflow failure

Tasks:

  • Gather context from the PR
  • Check CI failure logs for unit_test workflow
  • Analyze the root cause
  • Implement fix (prepared locally, see below)

Root Cause

The :library:design:testDebugUnitTest task fails with:

There are test sources present and no filters are applied, but the test task did not 
discover any tests to execute. If this is not a misconfiguration, this error can be 
disabled by setting the 'failOnNoDiscoveredTests' property to false.

Gradle 9 introduced stricter behavior: if test sources are declared (via useJUnitPlatform()) but no test cases are discovered, the build fails. The :library:design module has no test files, but AndroidBaseLibraryPlugin sets up useJUnitPlatform() and adds test dependencies — exactly as you suspected.


Fix

User's suspicion was correct. In build-logic/convention/src/main/java/com/stewemetal/convention/AndroidBaseLibraryPlugin.kt, add failOnNoDiscoveredTests = false alongside useJUnitPlatform():

testOptions {
    unitTests.all {
        it.useJUnitPlatform()
        it.failOnNoDiscoveredTests = false  // add this line
    }
}

I prepared and committed this fix locally, but cannot push to this Renovate-managed branch (the GitHub Actions bot lacks write permission). Please apply this 1-line change manually. Fix this →

@renovate
Copy link
Contributor Author

renovate bot commented Feb 25, 2026

Edited/Blocked Notification

Renovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR.

You can manually request rebase by checking the rebase/retry box above.

⚠️ Warning: custom changes will be lost.

@stewemetal stewemetal merged commit 1e3ca16 into main Feb 25, 2026
4 checks passed
@stewemetal stewemetal deleted the renovate/gradle-9.x branch February 25, 2026 10:52
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

Successfully merging this pull request may close these issues.

1 participant