Skip to content

chore: update all dependencies to latest versions#165

Merged
kirich1409 merged 2 commits intodevelopfrom
chore/update-deps
Mar 9, 2026
Merged

chore: update all dependencies to latest versions#165
kirich1409 merged 2 commits intodevelopfrom
chore/update-deps

Conversation

@kirich1409
Copy link
Collaborator

Summary

  • AGP 8.8.0 → 9.1.0 — migrated to built-in Kotlin support (removed kotlin-android plugin, deprecated kotlinOptions)
  • Kotlin 2.1.10 → 2.3.10
  • Gradle 8.12.1 → 9.4.0
  • compileSdk 35 → 36, minSdk 21 → 23, jvmTarget 11 → 17
  • AndroidX: activity 1.10.0→1.12.4, core 1.15.0→1.17.0, appcompat 1.7.0→1.7.1, fragment 1.8.5→1.8.9, test-core 1.6.1→1.7.0, test-runner 1.6.2→1.7.0
  • Removed deprecated android.defaults.buildfeatures.* properties from gradle.properties
  • Added robolectric.properties (sdk=35) for all test modules (Robolectric doesn't yet support SDK 36)

Breaking changes

  • minSdk raised from 21 to 23 — required by androidx.activity:1.12.x
  • jvmTarget raised from 11 to 17 — required by AGP 9.x

Test plan

  • ./gradlew check passes (build + unit tests + detekt + ktlint)
  • CI pipeline passes
  • Verify sample app builds and runs correctly

🤖 Generated with Claude Code

kirich1409 and others added 2 commits March 9, 2026 18:35
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- AGP 8.8.0 → 9.1.0 (migrate to built-in Kotlin, remove kotlin-android plugin)
- Kotlin 2.1.10 → 2.3.10
- Gradle wrapper 8.12.1 → 9.4.0
- compileSdk 35 → 36, minSdk 21 → 23, jvmTarget 11 → 17
- AndroidX: activity 1.10.0→1.12.4, core 1.15.0→1.17.0, appcompat 1.7.0→1.7.1,
  fragment 1.8.5→1.8.9, test-core 1.6.1→1.7.0, test-runner 1.6.2→1.7.0
- Remove deprecated android.defaults.buildfeatures.* properties
- Add robolectric.properties (sdk=35) for all test modules
- Remove deprecated kotlinOptions in favor of AGP 9 compilerOptions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings March 9, 2026 15:50
@qodo-code-review
Copy link

Review Summary by Qodo

Update all dependencies to latest versions with AGP 9 migration

✨ Enhancement

Grey Divider

Walkthroughs

Description
• Update AGP 8.8.0 → 9.1.0 with built-in Kotlin support
• Migrate from deprecated kotlinOptions to AGP 9 compilerOptions
• Upgrade Kotlin 2.1.10 → 2.3.10, Gradle 8.12.1 → 9.4.0
• Raise compileSdk 35 → 36, minSdk 21 → 23, jvmTarget 11 → 17
• Update AndroidX libraries and add Robolectric SDK 35 configuration
Diagram
flowchart LR
  AGP["AGP 8.8.0"] -- "upgrade to 9.1.0" --> AGP9["AGP 9.1.0"]
  KotlinOpts["kotlinOptions DSL"] -- "migrate to" --> CompilerOpts["compilerOptions"]
  Kotlin["Kotlin 2.1.10"] -- "upgrade to" --> Kotlin2["Kotlin 2.3.10"]
  Gradle["Gradle 8.12.1"] -- "upgrade to" --> Gradle9["Gradle 9.4.0"]
  SDK["SDK 35"] -- "upgrade to" --> SDK36["SDK 36"]
  MinSDK["minSdk 21"] -- "upgrade to" --> MinSDK23["minSdk 23"]
  JVM["jvmTarget 11"] -- "upgrade to" --> JVM17["jvmTarget 17"]
Loading

Grey Divider

File Changes

1. gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/dev/androidbroadcast/vbpd/gradle/BaseExtensions.kt ✨ Enhancement +0/-4

Remove deprecated kotlinOptions extension function

gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/dev/androidbroadcast/vbpd/gradle/BaseExtensions.kt


2. gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts ✨ Enhancement +0/-7

Remove kotlin-android plugin and kotlinOptions configuration

gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts


3. sample/build.gradle.kts ✨ Enhancement +0/-5

Remove kotlin-android plugin and kotlinOptions block

sample/build.gradle.kts


View more (6)
4. gradle.properties ⚙️ Configuration changes +0/-8

Remove deprecated android.defaults.buildfeatures properties

gradle.properties


5. gradle/libs.versions.toml Dependencies +12/-12

Update all dependency versions to latest releases

gradle/libs.versions.toml


6. gradle/wrapper/gradle-wrapper.properties Dependencies +1/-1

Update Gradle wrapper from 8.12.1 to 9.4.0

gradle/wrapper/gradle-wrapper.properties


7. vbpd-core/src/test/resources/robolectric.properties ⚙️ Configuration changes +1/-0

Add Robolectric SDK 35 configuration file

vbpd-core/src/test/resources/robolectric.properties


8. vbpd-reflection/src/test/resources/robolectric.properties ⚙️ Configuration changes +1/-0

Add Robolectric SDK 35 configuration file

vbpd-reflection/src/test/resources/robolectric.properties


9. vbpd/src/test/resources/robolectric.properties ⚙️ Configuration changes +1/-0

Add Robolectric SDK 35 configuration file

vbpd/src/test/resources/robolectric.properties


Grey Divider

Qodo Logo

@qodo-code-review
Copy link

qodo-code-review bot commented Mar 9, 2026

Code Review by Qodo

🐞 Bugs (2) 📘 Rule violations (1) 📎 Requirement gaps (0)

Grey Divider


Action required

1. jvmTarget set to 17 📘 Rule violation ✓ Correctness
Description
The version catalog sets jvmTarget to 17, which violates the requirement to keep JVM
bytecode/targets at 11. This can cause modules to compile for Java 17, breaking consumers and
violating the mandated JVM level.
Code

gradle/libs.versions.toml[15]

+jvmTarget = "17"
Evidence
Compliance requires JVM target/bytecode level 11 across Kotlin/Java modules, but the PR changes the
shared jvmTarget value to 17, and at least one module (sample) derives its Java compileOptions
from this value.

Rule 33296: Enforce JVM bytecode level 11 for all Kotlin/Java modules
Rule 33304: Enforce Java 11 as the JVM target in Gradle builds
gradle/libs.versions.toml[15-15]
sample/build.gradle.kts[19-22]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The PR configures `jvmTarget` as 17, but compliance requires Java/Kotlin bytecode target 11 across all JVM modules.

## Issue Context
`libs.versions.jvmTarget` is used by module build scripts (e.g., sample `compileOptions`) so changing it to 17 effectively makes the project compile for Java 17.

## Fix Focus Areas
- gradle/libs.versions.toml[15-15]
- sample/build.gradle.kts[19-22]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


2. Kotlin JVM target lost 🐞 Bug ✓ Correctness
Description
The PR removes kotlinOptions { jvmTarget = ... } but does not replace it with Kotlin
compilerOptions JVM target configuration, so Kotlin bytecode target is no longer pinned to the
repo’s intended jvmTarget=17 while Java is compiled for 17. This can produce mixed classfile targets
and can fail builds under stricter Kotlin JVM target validation or when using JVM-17-only bytecode
features.
Code

gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[L45-48]

-    kotlinOptions {
-        jvmTarget = libs.versions.jvmTarget.get()
-        freeCompilerArgs += listOf("-module-name", libraryId)
-    }
Evidence
The repo declares jvmTarget=17 and uses it for Java sourceCompatibility/targetCompatibility, but
Kotlin configuration now only sets the toolchain (JDK used), not the Kotlin compiler’s bytecode
target (jvmTarget). The sample module likewise sets Java compatibility to 17 but has no Kotlin
jvmTarget configuration.

gradle/libs.versions.toml[13-15]
gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[37-41]
gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[50-53]
sample/build.gradle.kts[19-22]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

### Issue description
Kotlin `jvmTarget` is no longer configured after removing `kotlinOptions { jvmTarget = ... }`. `jvmToolchain(17)` only selects the JDK used for compilation; it does not guarantee Kotlin bytecode is emitted for JVM 17.

### Issue Context
- Version catalog defines `jvmTarget = 17`.
- Java compilation is configured for 17.
- Kotlin configuration currently only sets toolchain.

### Fix Focus Areas
- gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[37-53]
- sample/build.gradle.kts[1-23]
- gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/dev/androidbroadcast/vbpd/gradle/BaseExtensions.kt[22-28]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools



Remediation recommended

3. CI SDK setup non-deterministic 🐞 Bug ⛯ Reliability
Description
CI workflows run Android Gradle tasks but never install/verify the required Android SDK packages
while the build now pins compileSdk=36 and buildToolsVersion=36.0.0, making CI depend on whatever is
preinstalled on the runner. This can cause CI breakages or flakiness when runner images change or
are missing those packages.
Code

gradle/libs.versions.toml[R2-4]

+android-compileSdk = "36"
+android-buildTools = "36.0.0"
+android-minSdk = "23"
Evidence
The PR bumps compileSdk/build-tools in the version catalog, and the build scripts explicitly set
buildToolsVersion from that catalog, but the CI workflows only set up Java and run Gradle without
installing Android SDK components.

gradle/libs.versions.toml[1-5]
gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[18-22]
sample/build.gradle.kts[6-10]
.github/workflows/android.yml[13-28]
.github/workflows/build.yml[12-30]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

### Issue description
CI currently relies on whatever Android SDK packages happen to be present on `ubuntu-latest`. After bumping `compileSdk` to 36 and pinning `buildToolsVersion` to 36.0.0, CI should explicitly install the required Android platform/build-tools to avoid breakages when runner images change.

### Issue Context
- Build requires compileSdk 36 and build-tools 36.0.0 from the version catalog.
- Workflows only set up Java and run Gradle.

### Fix Focus Areas
- .github/workflows/android.yml[13-28]
- .github/workflows/build.yml[12-30]
- gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[18-22]
- sample/build.gradle.kts[6-10]
- gradle/libs.versions.toml[1-5]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

ⓘ The new review experience is currently in Beta. Learn more

Grey Divider

Qodo Logo

@kirich1409 kirich1409 merged commit 55a6c7a into develop Mar 9, 2026
2 checks passed
kotlin = "2.3.10"
vanniktechMavenPublish = "0.30.0"
jvmTarget = "11"
jvmTarget = "17"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Action required

1. jvmtarget set to 17 📘 Rule violation ✓ Correctness

The version catalog sets jvmTarget to 17, which violates the requirement to keep JVM
bytecode/targets at 11. This can cause modules to compile for Java 17, breaking consumers and
violating the mandated JVM level.
Agent Prompt
## Issue description
The PR configures `jvmTarget` as 17, but compliance requires Java/Kotlin bytecode target 11 across all JVM modules.

## Issue Context
`libs.versions.jvmTarget` is used by module build scripts (e.g., sample `compileOptions`) so changing it to 17 effectively makes the project compile for Java 17.

## Fix Focus Areas
- gradle/libs.versions.toml[15-15]
- sample/build.gradle.kts[19-22]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AGP 9.x requires JVM 17+ — jvmTarget=11 is not compatible with AGP 9. This is not a rule violation, the old value was simply the previous project setting that needed to be updated along with the AGP major upgrade.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question:

AGP 9.x requires JVM 17+ — jvmTarget=11 is not compatible with AGP 9. This is not a rule violation, the old value was simply the previous project setting that needed to be updated along with the AGP major upgrade.

Answer:

You can reduce/avoid this kind of “false violation” by adding a repository-specific constraint to the agent prompt so it won’t recommend (or insist on) downgrading JVM bytecode targets when AGP 9.x is in use.

Add an explicit instruction that:

  • AGP 9.x implies JDK/JVM target 17+ (so don’t flag “jvmTarget=17” as a violation)
  • Only flag JVM target mismatches if they contradict an explicitly stated project policy in-repo

Suggested config (TOML):

[pr_code_suggestions]
extra_instructions = """\
- This repo uses Android Gradle Plugin (AGP) 9.x; therefore Java/Kotlin toolchain and jvmTarget are expected to be 17+.
- Do NOT suggest changing jvmTarget back to 11 just to match historical settings.
- Only raise a “rule/policy violation” if an explicit, authoritative repo policy file (e.g., best_practices.md / compliance checklist / build conventions) states a different required target.
- If there is a conflict (e.g., consumers require 11), present it as a trade-off with options (multi-module targets, toolchains, publishing strategy), not as an unconditional violation.
"""

[pr_reviewer]
extra_instructions = """\
- Treat jvmTarget=17 as acceptable when AGP 9.x is present; avoid calling it a compliance violation unless an explicit repo policy mandates 11.
"""

If this feedback is coming from the /compliance tool (rather than /improve or /review), the most robust fix is to update your pr_compliance_checklist.yaml to reflect the AGP 9.x baseline (17+) instead of 11.

Relevant Sources:

targetCompatibility = javaVersion
}

kotlinOptions {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Action required

2. Kotlin jvm target lost 🐞 Bug ✓ Correctness

The PR removes kotlinOptions { jvmTarget = ... } but does not replace it with Kotlin
compilerOptions JVM target configuration, so Kotlin bytecode target is no longer pinned to the
repo’s intended jvmTarget=17 while Java is compiled for 17. This can produce mixed classfile targets
and can fail builds under stricter Kotlin JVM target validation or when using JVM-17-only bytecode
features.
Agent Prompt
### Issue description
Kotlin `jvmTarget` is no longer configured after removing `kotlinOptions { jvmTarget = ... }`. `jvmToolchain(17)` only selects the JDK used for compilation; it does not guarantee Kotlin bytecode is emitted for JVM 17.

### Issue Context
- Version catalog defines `jvmTarget = 17`.
- Java compilation is configured for 17.
- Kotlin configuration currently only sets toolchain.

### Fix Focus Areas
- gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/vbpdconfig.gradle.kts[37-53]
- sample/build.gradle.kts[1-23]
- gradle/conventions-plugins/vbpd-library-base/src/main/kotlin/dev/androidbroadcast/vbpd/gradle/BaseExtensions.kt[22-28]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jvmToolchain(17) in Kotlin 1.7+ sets both the JDK toolchain AND the jvmTarget. Additionally, AGP 9's built-in Kotlin aligns the Kotlin target with compileOptions Java target. Both are configured to 17 — the Kotlin jvmTarget is not lost.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question:

jvmToolchain(17) in Kotlin 1.7+ sets both the JDK toolchain AND the jvmTarget. Additionally, AGP 9's built-in Kotlin aligns the Kotlin target with compileOptions Java target. Both are configured to 17 — the Kotlin jvmTarget is not lost.

Answer:

You can mitigate this kind of Gradle/Kotlin false-positive by adding explicit guidance via extra_instructions so the model verifies the effective Kotlin bytecode target before flagging “jvmTarget lost”, and treats jvmToolchain(...) / AGP alignment as acceptable evidence when applicable.

Add this to your repo (wiki/local/global) .pr_agent.toml:

[pr_code_suggestions]
extra_instructions = """\
When reviewing Gradle/Kotlin configuration changes:
- Do NOT claim 'Kotlin jvmTarget is lost' just because `kotlinOptions { jvmTarget = ... }` was removed.
- First verify whether Kotlin bytecode target is still effectively pinned via `jvmToolchain(<version>)`, Kotlin `compilerOptions`, or Android/AGP alignment with `compileOptions`.
- If the effective target remains consistent with Java (e.g., 17), do not open a bug; at most ask a clarifying question and cite the exact build files/lines that prove mismatch.
- Only raise a correctness bug when you can point to concrete evidence of mixed targets (Java 17 vs Kotlin != 17) in the diff/config.
"""

If this issue is being raised by /review rather than /improve, add the same idea there too:

[pr_reviewer]
extra_instructions = """\
For Gradle/Kotlin JVM target topics, verify the effective Kotlin bytecode target (toolchain/compilerOptions/AGP alignment) before claiming mismatch. Only flag when the diff shows concrete evidence of Kotlin target != Java target.
"""

To help you iterate, you can run:
/improve --config.output_relevant_configurations=true
to confirm which settings are actually applied.

Relevant Sources:

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This is a comprehensive dependency update PR that upgrades AGP from 8.8.0 to 9.1.0, Kotlin from 2.1.10 to 2.3.10, and Gradle from 8.12.1 to 9.4.0. The migration takes advantage of AGP 9's built-in Kotlin support by removing the separate kotlin-android plugin application and deprecated kotlinOptions blocks. Breaking changes include raising minSdk from 21 to 23 and jvmTarget from 11 to 17.

Changes:

  • Bumped all major build tool versions (AGP 9.1.0, Kotlin 2.3.10, Gradle 9.4.0) and AndroidX dependencies, with corresponding SDK and JVM target adjustments
  • Removed kotlin-android plugin application and deprecated kotlinOptions blocks in favor of AGP 9's built-in Kotlin support and kotlinConfig/jvmToolchain
  • Added robolectric.properties (sdk=35) for all test modules to work around Robolectric not yet supporting SDK 36, and cleaned up deprecated gradle properties

Reviewed changes

Copilot reviewed 9 out of 10 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
gradle/libs.versions.toml Version bumps for AGP, Kotlin, AndroidX libraries, compileSdk, minSdk, jvmTarget
gradle/wrapper/gradle-wrapper.properties Gradle wrapper updated to 9.4.0
gradle/conventions-plugins/.../vbpdconfig.gradle.kts Removed kotlin-android plugin application and kotlinOptions block
gradle/conventions-plugins/.../BaseExtensions.kt Removed kotlinOptions extension function and its import
sample/build.gradle.kts Removed kotlin-android plugin and kotlinOptions block
gradle.properties Removed deprecated android.defaults.buildfeatures.* properties
vbpd/src/test/resources/robolectric.properties New file pinning Robolectric to SDK 35
vbpd-core/src/test/resources/robolectric.properties New file pinning Robolectric to SDK 35
vbpd-reflection/src/test/resources/robolectric.properties New file pinning Robolectric to SDK 35
.gitignore Added .worktrees/ directory

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment on lines 40 to 45
targetCompatibility = javaVersion
}

kotlinOptions {
jvmTarget = libs.versions.jvmTarget.get()
freeCompilerArgs += listOf("-module-name", libraryId)
}

testOptions {
unitTests {
isIncludeAndroidResources = true
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The -module-name free compiler argument that was previously set in the kotlinOptions block has been dropped and not migrated. This argument set a custom Kotlin module name (e.g., dev.androidbroadcast.vbpd.core) for each published library module, which prevents Kotlin module name clashes when consumers depend on multiple modules from this library.

The equivalent should be added in the kotlinConfig block using compilerOptions, e.g., compilerOptions { freeCompilerArgs.addAll("-module-name", libraryId) }.

Copilot uses AI. Check for mistakes.
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AGP 9 automatically sets -module-name from the namespace property, which is already set to libraryId in this convention plugin (line 19). Verified: compilation produces no warnings, and the module names match the previous values. Adding it manually caused a "passed multiple times" warning with AGP 9.

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.

2 participants