Skip to content

Upgrade AndroidX Lifecycle to 2.8.7 - #205

Open
dipenpradhan wants to merge 2 commits into
Gurupreet:masterfrom
dipenpradhan:issue-192-lifecycle-2.8
Open

Upgrade AndroidX Lifecycle to 2.8.7#205
dipenpradhan wants to merge 2 commits into
Gurupreet:masterfrom
dipenpradhan:issue-192-lifecycle-2.8

Conversation

@dipenpradhan

@dipenpradhan dipenpradhan commented Jun 7, 2026

Copy link
Copy Markdown
Collaborator

📚 Stacked PR — 4 of 18

Depends on #204 · Blocks #206

This PR's own diff (1 commit)

The diff shown below by GitHub also includes the ancestor commits, because
every PR in this stack targets master (base branches can only point at
branches that exist in this repository). Use the compare link above to review
just this PR's real change. Merge order is documented in the stack.

Summary

Upgrades all AndroidX Lifecycle artifacts from 2.7.0 to 2.8.7, as proposed in #192.

All five artifacts pinned to Versions.androidLifecycleGrouped move together: lifecycle-viewmodel-compose, lifecycle-viewmodel-ktx, lifecycle-livedata-ktx, lifecycle-runtime-ktx, lifecycle-viewmodel-savedstate.

This lands after the Compose BOM PR on purpose: Lifecycle 2.8.x is compiled against Compose 1.7, so sequencing it after #204 avoids the known LocalLifecycleOwner runtime incompatibility with Compose 1.6.

The issue's suggestion to migrate DisposableEffect(lifecycleOwner) call sites to the new LifecycleEventEffect/LifecycleResumeEffect APIs is left as a follow-up — no behavioral change is bundled into this version bump.

Closes #192

Verification

  • ./gradlew ktfmtCheck assembleDebug testDebugUnitTest passes locally (JDK 17, SDK 35)
  • CI ./gradlew build on this PR

cc @Gurupreet for review

- Replace compose/material3 version constants with composeBom
- Strip explicit versions from BOM-managed artifacts
- Import the BOM platform on every configuration that receives
  Compose artifacts (implementation, debugImplementation,
  androidTestImplementation, :data)
- Migrate API removals that come with Compose 1.7 / Material3 1.3:
  SmallTopAppBar -> TopAppBar, rememberRipple -> material3 ripple
- Update the outdated README Compose badge to the BOM version

Fixes Gurupreet#186
All lifecycle artifacts (viewmodel-compose, viewmodel-ktx,
livedata-ktx, runtime-ktx, viewmodel-savedstate) move together
via the shared androidLifecycleGrouped version.

Fixes Gurupreet#192
@dipenpradhan
dipenpradhan force-pushed the issue-192-lifecycle-2.8 branch from 272e4ed to 996b581 Compare September 9, 2026 07:06
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.

Enhancement: Upgrade AndroidX Lifecycle to 2.8.x

2 participants