Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash in version 7.1 #173

Open
robertlevonyan opened this issue Mar 10, 2022 · 4 comments
Open

Crash in version 7.1 #173

robertlevonyan opened this issue Mar 10, 2022 · 4 comments

Comments

@robertlevonyan
Copy link

atal Exception: java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
       at androidx.fragment.app.FragmentManager.checkStateLoss(FragmentManager.java:1)
       at androidx.fragment.app.BackStackRecord.commitInternal(BackStackRecord.java:4)
       at androidx.fragment.app.BackStackRecord.commit(BackStackRecord.java:1)
       at com.github.terrakok.cicerone.androidx.AppNavigator.commitNewFragmentScreen(AppNavigator.java:9)
       at com.github.terrakok.cicerone.androidx.AppNavigator.replace(AppNavigator.java:5)
       at com.github.terrakok.cicerone.androidx.AppNavigator.applyCommands(AppNavigator.java:7)
       at com.robertlevonyan.testy.ui.main.MainFragment.onItemSelected$lambda-10$lambda-9(MainFragment.java:53)
       at androidx.camera.camera2.internal.Camera2CameraControlImpl$CameraCaptureCallbackSet$$InternalSyntheticLambda$9$e5350c1b11be8bdf6a3182cb638daed28e6e5f26d5bae717586c49615918254f$0.run$bridge(Camera2CameraControlImpl.java:53)
       at android.os.Handler.handleCallback(Handler.java:938)
       at android.os.Handler.dispatchMessage(Handler.java:99)
       at android.os.Looper.loop(Looper.java:236)
       at android.app.ActivityThread.main(ActivityThread.java:8059)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:656)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:967)
@lyrjie
Copy link

lyrjie commented May 15, 2023

@terrakok , hello
Is there a current maintainer for the library? There haven't been any work in last two years and critical issues like this one are left without a comment for more than a year
Could you please mark the repository as unsupported / deprecated, if it's an orphan

@terrakok
Copy link
Owner

Hello! I'm here and there are no contributions for two reasons:

  1. the reported one is not a library issue but a FragmentManager behavior which was discussed lots of times.
  2. library is stable enough at the moment. and since Compose for Android is recommended way to make applications, I don't have ideas to develop the library

If you have ideas PRs are more than welcome!

Regarding the issue: #160

@VitalyPeryatin may add a comment here, I guess.

@lyrjie
Copy link

lyrjie commented May 15, 2023

This current issue is reproducible on 7.1
As far as I understand the comment, it assumes the Router is cleared in onPause; which is an assumation on the user's app architecture. Meanwhile, I've seen some developers inject Router directly into, for example, presenter, meaning there's no onPause handling. It's, of course, for you to decide whether to support such a usage or not

Thanks for the prompt answer!

@Zhuinden
Copy link

Zhuinden commented Jul 17, 2023

This current issue is reproducible on 7.1 As far as I understand the comment, it assumes the Router is cleared in onPause; which is an assumation on the user's app architecture. Meanwhile, I've seen some developers inject Router directly into, for example, presenter, meaning there's no onPause handling. It's, of course, for you to decide whether to support such a usage or not

Thanks for the prompt answer!

That's a bug on library user's part, they should observe ProcessLifecycleOwner to know attach/detach of the app itself if they don't control the NavigationHolder otherwise from Fragment lifecycle.

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

No branches or pull requests

4 participants