Fixed
Status Update
Comments
lo...@gmail.com <lo...@gmail.com> #2
It's not just EditTextPreference related problem, just to clarify things. ListPreference throws the same exception.
ma...@google.com <ma...@google.com>
ap...@google.com <ap...@google.com> #3
That stack trace implies that the preference that the dialog is based on couldn't be found. That could happen for obvious reasons (not loading the correct set of preference items in onCreatePreferences) or for subtle reasons (fragments getting onCreate called in an unexpected order).
na...@google.com <na...@google.com> #4
This only appears on a specific order of adding Fragment instances and making them active in an Activity. I mean there are chances to not get the exception. The problem lies in the mActive List of active Fragment instances in the FragmentManager of the Activity. When restoring the state of the Activity on orientation change, in some cases the child PreferenceDialogFragmentCompat is created before the parent/target Fragment's onCreate() got called (if its position index in mActive List is lower). So the preference (requested in the onCreate() of the PreferenceDialogFragmentCompat through the parent/target Fragment) in the parent/target Fragment is not initialized. Maybe this helps to fix this issue.
Description
Component used: Jetpack macrobenchmark Version used: 1.4.0-alpha07 Devices/Android versions reproduced on: Pixel 4 XL Android 14 aosp
Sometimes there are resynced frames when frame is prepared for too long: "Choreographer#doFrame - resynced to 8643135 in 21,7ms" and there is logic added here to filter these out in FrameTimingQuery:
But there's a check later that checks if all slices have frameId:
Frame id is number that comes after "Choreographer#doFrame" And it checks for frameId in unfiltered slices where
Choreographer#doFrame - resynced to 8643135 in 21,7ms
is present. It tries to convert"-"
to id, fails to do so and returns null.It results in test failing because of that check.
Should be easy fix - just filter first and check for frameIds presence in filtered traces