Skip to content

ref(android): [Part 1] Refactor - #6481

Open
0xadam-brown wants to merge 1 commit into
feat/nav3-lifecyclefrom
ref/nav3-lifecycle-1-nav-roots
Open

0xadam-brown wants to merge 1 commit into
feat/nav3-lifecyclefrom
ref/nav3-lifecycle-1-nav-roots

Conversation

@0xadam-brown

@0xadam-brown 0xadam-brown commented Nov 6, 2026 •

Copy link
Copy Markdown
Member

PR Stack (Nav3 Lifecycle)


📜 Description

Groundwork for the rest of this PR stack. No behavior changes.

[1] Introduces NavRootInfo: Gives us a place to define "nav root", and will let us encapsulate multiple pieces of info from the nav root in future PRs in this stack.

[2] Renames some types, members, etc. for clarity and consistency: LeasedNavState → INavStatePublisher, hasAppliedInitialBackStackUpdate → hasHandledFirstUpdate / canReceiveLease, etc.

[3] Adds a compileOnly dep on androidx.compose.ui: Used to provide LocalContext, which will be needed in subsequent PRs.

[4] Doc improvements, etc.

💡 Motivation and Context

Confines trivial updates to a single PR and keeps later PRs cleaner.

💚 How did you test it?

📝 Checklist

  • I added GH Issue ID & Linear ID
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.
  • Public API changes reviewed by another Mobile SDK team member or implemented according to the develop docs spec.

🔮 Next steps

The next PR in the stack starts a new nav transaction when the user returns to a Nav3 root.

#skip-changelog

⚠️ Merge this PR using a merge commit (not squash). Only the collection branch is squash-merged into main.

… the README

Prepares the Nav3 lifecycle stack without changing behavior. SentryNavEffect now attaches a NavRootInfo (the nav root's lifecycle plus the Activity that displays it), which later lease withdrawal needs. Renames LeasedNavState to INavStatePublisher, publisher to lastPublisher, and hasAppliedInitialBackStackUpdate to hasHandledFirstUpdate/canReceiveLease, and says "nav root" rather than "owner" throughout.

The lease policy (tradeoff, handoff, diagram) moves from the NavLeaseCoordinator KDoc to the package README, so later changes to the policy are reviewed as prose.
@sentry

sentry Bot commented Nov 6, 2026

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
SDK Size io.sentry.tests.size 8.63.0 (1) release

⚙️ sentry-android Build Distribution Settings

@0xadam-brown 0xadam-brown changed the title ref(android): [Nav3 Lifecycle 1] Introduce NavRootInfo and move the lease policy to the README ref(android): [Part 1] Refactored groundwork Nov 6, 2026
@0xadam-brown 0xadam-brown changed the title ref(android): [Part 1] Refactored groundwork ref(android): [Part 1] Refactor Nov 6, 2026
@0xadam-brown
0xadam-brown marked this pull request as ready for review November 6, 2026 12:31
@0xadam-brown
0xadam-brown requested review from a team and adinauer as code owners November 6, 2026 12:31
@0xadam-brown
0xadam-brown requested review from romtsn and runningcode and removed request for a team November 6, 2026 12:31
@0xadam-brown 0xadam-brown added the ship-it PR is ready to merge from a reviewer perspective label Nov 6, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ship-it PR is ready to merge from a reviewer perspective

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant