Skip to content

Bump navigation3 to 1.2.0-alpha07 and fix DeepLinkMatcher signatures - #3054

Open
StylianosGakis wants to merge 1 commit into
developfrom
chore/nav3-alpha07
Open

Bump navigation3 to 1.2.0-alpha07 and fix DeepLinkMatcher signatures#3054
StylianosGakis wants to merge 1 commit into
developfrom
chore/nav3-alpha07

Conversation

@StylianosGakis

@StylianosGakis StylianosGakis commented Aug 13, 2026

Copy link
Copy Markdown
Member

Adapt to the new navigation3 deep link API
No important changes, but the code change is source breaking so we had to update it.

AI summary:

What

Bumps androidx.navigation3 from 1.2.0-alpha06 to 1.2.0-alpha07 and adapts to the one source-breaking API change in that release.

Why

alpha07 gives DeepLinkMatcher a second type parameter for its match-result type:

// alpha06:  DeepLinkMatcher<out T : Any>
// alpha07:  DeepLinkMatcher<out T : Any, out R : MatchResult<out T>>

Every aggregation-side usage is widened to a star projection DeepLinkMatcher<HedvigNavKey, *>. The matcher registry is heterogeneous (mixed matcher/result types ranked through their common MatchResult base) and never observes the concrete result type, so the star is the accurate type here, not a workaround.

UriDeepLinkMatcher<T> and StaticKeyDeepLinkMatcher<T> keep their single type parameter (they fix R internally), so the UriDeepLinkMatcher subclass in feature-addon-purchase needs no change.

Scope

  • gradle/libs.versions.toml version bump
  • HedvigDeepLinkMatcher / DeepLinkMatcherProvider in navigation-compose
  • 20 feature *DeepLinks.kt matchers() override return types

Verification

  • :navigation-compose compiles on JVM and iOS (KMP common deep link code)
  • :app:compileDebugKotlin (transitively compiles all feature modules)
  • :navigation-compose:jvmTest --tests "*DeepLink*" passes
  • :app deep link + synthetic stack tests pass
  • :navigation-compose:ktlintCheck passes

alpha07 gives DeepLinkMatcher a second type parameter for its match-result
type (DeepLinkMatcher<T, R : MatchResult<out T>>). Widen every aggregation-side
usage to a star projection (DeepLinkMatcher<HedvigNavKey, *>), since the matcher
registry is heterogeneous and does not name a concrete result type.

UriDeepLinkMatcher and StaticKeyDeepLinkMatcher keep their single type
parameter, so the UriDeepLinkMatcher subclass needs no change.
@StylianosGakis
StylianosGakis requested a review from a team as a code owner August 13, 2026 15:14
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