Status Update
Comments
wi...@gmail.com <wi...@gmail.com> #2
Hey Doris, any ideas on where this random animation could be coming from?
jb...@google.com <jb...@google.com>
cl...@google.com <cl...@google.com>
ap...@google.com <ap...@google.com> #3
Re
I tried the repro project locally. I was not able to reproduce in the the tip of tree compose code base, after dozens of attempts. It's possible the issue has been fixed recently.
Could you try the latest androidx snapshot here:
cl...@google.com <cl...@google.com> #4
Hi! Thank you for checking into it and giving it a try.
Unfortunately, the issue is still reproducible with snapshot 12123985, 2.8.0-SNAPSHOT for navigation, and 1.8.0-SNAPSHOT for compose.
I've pushed an update containing SNAPSHOT dependencies and automated reproduction attempts:
Now, it's sufficient to launch the application and wait.
Here's a new video:
pr...@google.com <pr...@google.com> #5
Thanks for the repro in
Initial investigation showed that the enter/exit transitions are correct. What appears like a scale animation is a size transform. During the repeated destination change, there seems to be a frame where the new content is resolved into an empty list of measurables, which is incorrect.
Unclear what's causing this yet - either the content composable is not yet populated for that frame, or the UI tree applier deferred adding the nodes to the tree to the next frame. More investigation will be needed.
Description
Version used: 2.7.7
Devices/Android versions reproduced on: Pixel 3, Pixel 7 Pro
We recently experienced an app crash when switching our NavHost's startDestination. After some investigation, it seems like this is triggered only after having previously navigated between two routes, where the second route is nested inside of a nav graph whose route has the same name as a sibling of the starting route (causing them to have the same ID).
Fortunately, this means the crash can be avoided by avoiding those duplicates, but it was a bit tricky to find the cause of the NullPointerException, and it would be nice if it failed more gracefully than a NullPointerException with the possibility of crashing the app entirely.
I have attached a sample app which reproduces this crash.