Status Update
Comments
jb...@google.com <jb...@google.com> #2
Please include a sample project that reproduces your issue.
ax...@gmail.com <ax...@gmail.com> #3
Steps to reproduce:
1. Press on "Search" icon;
2. Write something;
3. Search this text, keyboard will be dismissed;
4. Tap on "Dialog" button;
5. Dissmiss dialog;
With the new 1.5.0 fragment library version text will be cleared in the search box after dismissing dialog.
In the version 1.4.1 and lower text in the search is not clearing and this is correct behaviour.
Please suggest some workarounds or how to fix this issue?
jo...@meterapp.co <jo...@meterapp.co> #4
jo...@meterapp.co <jo...@meterapp.co> #5
jb...@google.com <jb...@google.com>
fa...@gmail.com <fa...@gmail.com> #6
jo...@meterapp.co <jo...@meterapp.co> #7
Hello
I raised similar issue with this ticket
This makes the SearchView unusable/broken when fragments are changed (i.e base on searchView input query)
What can we do to fix this problem? What is the progress of work on solving this problem?
ap...@google.com <ap...@google.com> #8
jb...@google.com <jb...@google.com> #9
Any idea on when it will be fixed?
jo...@meterapp.co <jo...@meterapp.co> #10
jb...@google.com <jb...@google.com> #11
Can you update regarding any progress on this issue.
jo...@meterapp.co <jo...@meterapp.co> #12
jb...@google.com <jb...@google.com> #13
Branch: androidx-main
commit 50f098644adc703ae218b0b7e999629f516a0241
Author: sanura <sanura@google.com>
Date: Thu Mar 02 00:11:35 2023
Add check to only invalidate options menu when contributing menu items
FragmentManager previously appropriately only added
a MenuProvider when the host is a MenuHost **and**
we are at the root fragment that is providing the
menu items. This behavior should be mirrored when
removing a MenuProvider as well, so that only
components that directly contribute menu items will
invalidate the options menu.
Bug: 244336571
Test: all tests pass
Change-Id: I9404ee9fcc9ce6b80d70a93bea720fe4ccf583a0
M fragment/fragment/src/androidTest/java/androidx/fragment/app/FragmentContainerInflatedFragmentTest.kt
M fragment/fragment/src/androidTest/java/androidx/fragment/app/OptionsMenuFragmentTest.kt
M fragment/fragment/src/androidTest/java/androidx/fragment/app/test/FragmentTestActivity.kt
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentActivity.java
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentManager.java
jo...@meterapp.co <jo...@meterapp.co> #14
Please show what to write on gradle file.
jo...@meterapp.co <jo...@meterapp.co> #15
This has been fixed internally and will be available in the Fragment 1.6.0-alpha07
release.
jb...@google.com <jb...@google.com> #16
It's part of the material dependency, perhaps?
kl...@gmail.com <kl...@gmail.com> #17
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.fragment:fragment:1.6.0-alpha07
jo...@meterapp.co <jo...@meterapp.co> #18
ha...@gmail.com <ha...@gmail.com> #19
It says "Duplicate class found".
The IDE doesn't provide any useful explanation of what is the class that is duplicated and what to do about it.
Please help.
pr...@google.com <pr...@google.com> #20
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.fragment:fragment:1.5.6
8h...@gmail.com <8h...@gmail.com> #21
jo...@meterapp.co <jo...@meterapp.co> #22
@21 androidx.fragment:fragment:1.5.6 is a STABLE release. It has the fix we need. The androidx.fragment:fragment:1.6.0-alpha07 is an alpha as it says. 1.6 is "work in progress". 1.6.0 is still not a stable release. Use "alpha" only for testing
il...@google.com <il...@google.com> #23
jb...@google.com <jb...@google.com>
ud...@gmail.com <ud...@gmail.com> #24
composeBom = "2024.09.02"
navigation = "2.8.1"
activityCompose = "1.9.2"
appcompat = "1.7.0"
fa...@cosmoconnected.com <fa...@cosmoconnected.com> #25
It can be reproduced easily when fast navigation between menu.
enableOnBackInvokedCallback="true"
navigation = "2.8.1"
activityCompose = "1.9.2"
appcompat = "1.7.0"
ap...@google.com <ap...@google.com> #26
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Fix failing PredictiveBackHandler enabled changes
Expand for full commit details
Fix failing PredictiveBackHandler enabled changes
As part of asop/3164566 we attempted to fix an error with
PredictiveBackHandler by closing the internal onBackInstance when the
enabled status changed. This would have worked, except by the time we
made it to the LaunchedEffect the onBackInstance was always null, so we
weren't closing anything.
I believe the cause of this is that `onBackInstance` was a field of a
function and we couldn't reference it across different calls. Because we
needed to change it as part of the backCallback, it also could not be
remembered.
So instead of using the onBackInstance, we can just use the callback
`isEnabled` state directly by passing the callback to the
`OnBackInstance`. This ensures that we only fire the `onBack` callback
when the function is actually enabled.
Test: PredictiveBackHandlerTest, tested and confirmed in sample app
Bug: 365027664
Bug: 340202286
RelNote: "`PredictiveBackHandler` will no longer fire it's callback
after the handler has been disabled. This will fix an issue where
the `NavHost` from Navigation Compose would throw an
`IndexOutOfBoundsException`."
Change-Id: I3f75eb2415f39b914f18cf4b87bf4ed57bb5a483
Files:
- M
activity/activity-compose/src/androidTest/java/androidx/activity/compose/PredictiveBackHandlerTest.kt
- M
activity/activity-compose/src/main/java/androidx/activity/compose/PredictiveBackHandler.kt
Hash: 1658eca1da25d8092f3cd48806946edcdec73688
Date: Thu Sep 26 18:15:59 2024
jb...@google.com <jb...@google.com> #27
This has been fixed internally and will be available in Activity 1.9.3
version.
nu...@idoctus.com <nu...@idoctus.com> #28
jo...@meterapp.co <jo...@meterapp.co> #29
This has been fixed internally and will be available in Activity 1.9.3 version.
So excited for that release, thank you for your persistence on this issue Jeremy!
Do we have a timeline for the Activity 1.9.3 release?
comment#28
The release most likely will be October 16th if it is getting released in the next release cycle that andoidx libraries have (2 week release cycle)
Activity 1.9.2 is scheduled for September 4th, but you can try out the fix now with snapshots.
comment#11
If you'd like to try it out earlier, this commit is most likely in the snapshots
na...@google.com <na...@google.com> #30
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.activity:activity-compose:1.9.3
jo...@meterapp.co <jo...@meterapp.co> #31
It seemed to address the crash on the 1.10.0 snapshot, will test 1.9.3 now that its in production and let the group know
la...@gmail.com <la...@gmail.com> #32
Thanks for this update! This has been affecting our users using navigation-compose = "2.8.2"
and activity-compose = "1.9.2"
.
bi...@gmail.com <bi...@gmail.com> #33
java.lang.IndexOutOfBoundsException: Index -1 out of bounds for length 1
at jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64)
at jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70)
at jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266)
at java.util.Objects.checkIndex(Objects.java:359)
at java.util.ArrayList.get(ArrayList.java:434)
at androidx.navigation.compose.NavHostKt$NavHost$28$1.invokeSuspend(NavHost.kt:611)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:101)
at androidx.compose.ui.platform.AndroidUiDispatcher.performTrampolineDispatch(AndroidUiDispatcher.android.kt:81)
at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(AndroidUiDispatcher.android.kt:41)
at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.run(AndroidUiDispatcher.android.kt:57)
at android.os.Handler.handleCallback(Handler.java:958)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:230)
at android.os.Looper.loop(Looper.java:319)
at android.app.ActivityThread.main(ActivityThread.java:8919)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:578)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)
jb...@google.com <jb...@google.com> #34
That stacktrace indicates that we have somehow collected back events without ever starting them? Do you have a minimal sample project that can reproduce that error?
bi...@gmail.com <bi...@gmail.com> #35
From what I see from Sentry :
- it seems to occur AFTER (a few seconds to a minute) my mainActivity got stopped/destroyed/detached.
- 100% of the affected users are with a SAMSUNG device and on Android 14
I don't get it..
Don't know if it's related but I have 2 nested navControllers/navHost (a main one, and one dedicated to handle bottomNavigation). But everything works smoothly and I'm not even sure if users "see" the bug occuring (got no complaints) ..
am...@gmail.com <am...@gmail.com> #36
at java.util.ArrayList.get(ArrayList.java:310)
at androidx.navigation.compose.NavHostKt$NavHost$25$1.invokeSuspend(NavHost.kt:518)
at androidx.navigation.compose.NavHostKt$NavHost$25$1.invoke(NavHost.kt:1)
at androidx.navigation.compose.NavHostKt$NavHost$25$1.invoke(NavHost.kt:2)
at androidx.activity.compose.OnBackInstance$job$1.invokeSuspend(PredictiveBackHandler.kt:154)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:108)
at androidx.compose.ui.platform.AndroidUiDispatcher.performTrampolineDispatch(AndroidUiDispatcher.android.kt:81)
at androidx.compose.ui.platform.AndroidUiDispatcher.access$setScheduledFrameDispatch$p(AndroidUiDispatcher.android.kt:41)
at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(AndroidUiDispatcher.android.kt:41)
at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.doFrame(AndroidUiDispatcher.android.kt:68)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:909)
at android.view.Choreographer.doCallbacks(Choreographer.java:686)
at android.view.Choreographer.doFrame(Choreographer.java:619)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:897)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:7406)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
does any one find the solution i'm using def nav_version = "2.8.0"
nu...@idoctus.com <nu...@idoctus.com> #37
li...@gmail.com <li...@gmail.com> #38
jb...@google.com <jb...@google.com> #39
Please file a new bug with a minimal sample project that reproduces this error.
jo...@meterapp.co <jo...@meterapp.co> #40
Same as above the stack trace changed but there is still a crash. Anyone know if its the same repro as before?
The steps to repro the first crash are somewhat tricky and require good timing
- Start the app in debug mode (or use a really old phone). This seems to help to reproduce the crash because it creates a bigger window for clicking the back button at the right time
- Navigate to a new screen while simultaneously or a split second later pressing the back button. I mash the back button right after clicking on a button to open a screen
Fatal Exception: java.lang.IndexOutOfBoundsException: Index -1 out of bounds for length 1
at jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64)
at jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70)
at jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266)
at java.util.Objects.checkIndex(Objects.java:359)
at java.util.ArrayList.get(ArrayList.java:434)
at androidx.navigation.compose.NavHostKt$NavHost$28$1.invokeSuspend(NavHost.kt:611)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:101)
at androidx.compose.ui.platform.AndroidUiDispatcher.performTrampolineDispatch(AndroidUiDispatcher.android.kt:81)
at androidx.compose.ui.platform.AndroidUiDispatcher.access$setScheduledFrameDispatch$p(AndroidUiDispatcher.android.kt:41)
at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(AndroidUiDispatcher.android.kt:41)
at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.run(AndroidUiDispatcher.android.kt:57)
at android.os.Handler.handleCallback(Handler.java:958)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:257)
at android.os.Looper.loop(Looper.java:368)
at android.app.ActivityThread.main(ActivityThread.java:8839)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:572)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1049)
si...@gmail.com <si...@gmail.com> #41
I have created a new issue in
jo...@meterapp.co <jo...@meterapp.co> #42
I have created a new issue in
, as requested. https://issuetracker.google.com/issues/375343407
Thanks for reporting this! Its my biggest crash by fare, hopefully we can resolve soon
pr...@google.com <pr...@google.com> #43
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.activity:activity-compose:1.10.0-alpha03
sh...@gmail.com <sh...@gmail.com> #44
I also same issues, It was as though val previousEntry = currentBackStack[currentBackStack.size - 2]
, NavHost.kt
, didn't guard this situation.
java.lang.IndexOutOfBoundsException: Index -1 out of bounds for length 1 at jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64) at jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70) at jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266) at java.util.Objects.checkIndex(Objects.java:359) at java.util.ArrayList.get(ArrayList.java:434) at androidx.navigation.compose.NavHostKt$NavHost$25$1.invokeSuspend(NavHost.kt:518) at androidx.navigation.compose.NavHostKt$NavHost$25$1.invoke(Unknown Source:8) at androidx.navigation.compose.NavHostKt$NavHost$25$1.invoke(Unknown Source:4) at androidx.activity.compose.OnBackInstance$job$1.invokeSuspend(PredictiveBackHandler.kt:121) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:108) at androidx.compose.ui.platform.AndroidUiDispatcher.performTrampolineDispatch(AndroidUiDispatcher.android.kt:81) at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(AndroidUiDispatcher.android.kt:41) at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.run(AndroidUiDispatcher.android.kt:57) at android.os.Handler.handleCallback(Handler.java:958) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loopOnce(Looper.java:230) at android.os.Looper.loop(Looper.java:319) at android.app.ActivityThread.main(ActivityThread.java:8919) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:578) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103) Suppressed: kotlinx.coroutines.internal.DiagnosticCoroutineContextException: [androidx.compose.ui.platform.MotionDurationScaleImpl@5133892, androidx.compose.runtime.BroadcastFrameClock@757c263, StandaloneCoroutine{Cancelling}@92a1e60, AndroidUiDispatcher@a705f19]
sh...@gmail.com <sh...@gmail.com> #45
Additional information activity-compose: 1.10.0-alpha03 navigation-compose: 2.9.0-alpha02
[Deleted User] <[Deleted User]> #46
nu...@idoctus.com <nu...@idoctus.com> #47
ma...@gmail.com <ma...@gmail.com> #48
I was not seeing the crash when running 'androidx.navigation:navigation-compose:2.7.2'
jo...@meterapp.co <jo...@meterapp.co> #49
The resolution of this issue has unfortunately led to a new problem, which is now tracked under Issue
If there’s any way I can help get this new issue assigned to an owner or provide further information, please let me know.
su...@gmail.com <su...@gmail.com> #50
W
Description
Component used: Navigation Version used: lastest Devices/Android versions reproduced on: any
java.lang.IndexOutOfBoundsException: Index -1 out of bounds for length 1 at jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64) at jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70) at jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266) at java.util.Objects.checkIndex(Objects.java:359) at java.util.ArrayList.get(ArrayList.java:434) at androidx.navigation.compose.NavHostKt$NavHost$17$1.invokeSuspend(NavHost.kt:342) at androidx.navigation.compose.NavHostKt$NavHost$17$1.invoke(Unknown Source:8) at androidx.navigation.compose.NavHostKt$NavHost$17$1.invoke(Unknown Source:4) at androidx.activity.compose.OnBackInstance$job$1.invokeSuspend(PredictiveBackHandler.kt:154) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:108) at androidx.compose.ui.platform.AndroidUiDispatcher.performTrampolineDispatch(AndroidUiDispatcher.android.kt:81) at androidx.compose.ui.platform.AndroidUiDispatcher.access$performTrampolineDispatch(AndroidUiDispatcher.android.kt:41) at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.run(AndroidUiDispatcher.android.kt:57) at android.os.Handler.handleCallback(Handler.java:942) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loopOnce(Looper.java:204) at android.os.Looper.loop(Looper.java:291) at android.app.ActivityThread.main(ActivityThread.java:8134) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:588) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1019) Suppressed: kotlinx.coroutines.internal.DiagnosticCoroutineContextException: [androidx.compose.ui.platform.MotionDurationScaleImpl@5863fee, androidx.compose.runtime.BroadcastFrameClock@1b7ec8f, StandaloneCoroutine{Cancelling}@afd7b1c, AndroidUiDispatcher@d182325]