-
Notifications
You must be signed in to change notification settings - Fork 367
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
IllegalStateException: Can not perform this action after onSaveInstanceState #516
Comments
v5.2.1 - crash is still there
Problematic code: private void cleanUp() {
if (!mCleanedUp) {
mHandler.removeCallbacks(mRemover);
mHandler.removeCallbacks(mDisplayMini);
UpdateDisplayState.releaseDisplayState(mDisplayStateId);
final FragmentManager fragmentManager = mParent.getFragmentManager();
FragmentTransaction transaction = fragmentManager.beginTransaction();
transaction.remove(this).commit();
}
mCleanedUp = true;
} Cause of the problem:
Possible solution:
Take a look into Lifecycle in Depth https://imgur.com/lUtGxVO |
and make mCleanedUp AtomicBoolean or transient |
Having the same issue: (using compile "com.mixpanel.android:mixpanel-android:5.1.3")
|
Thanks for reporting this guys, will take a look at it soon. |
any idea when it will be released?! this issue is the most often crash in our app now. |
Try fixing like this private void cleanUp() {
|
@OleksandrKucherenko based on your comment, is your suspicion that |
Seems that Available in the latest release 5.2.4 |
Have to re-open the ticket. http://crashes.to/s/4715c08ed20 code changes raise another exception in the same place. |
@patedit ^ |
Hi @OleksandrKucherenko ! I've opened a PR that will address your issue. Would love to hear what you think. Thank you very much for reporting this! |
Issue is solved in v5.3.1. Thanks for writing in! |
What is the reason to save the state if you are ok with commitAllowingStateLoss? This not a fix I believe this is just creating another bug on top of the exception |
Issues returns back, reference #205
The text was updated successfully, but these errors were encountered: