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

App crashes when saving state in MessageCompose #6863

Closed
2 tasks done
cketti opened this issue May 1, 2023 · 1 comment · Fixed by #6864
Closed
2 tasks done

App crashes when saving state in MessageCompose #6863

cketti opened this issue May 1, 2023 · 1 comment · Fixed by #6864
Assignees
Labels
type: bug Something is causing incorrect behavior or errors

Comments

@cketti
Copy link
Member

cketti commented May 1, 2023

Checklist

  • I have used the search function to see if someone else has already submitted the same bug report.
  • I will describe the problem with as much detail as possible.

App version

6.701

Where did you get the app from?

None

Android version

12

Device model

No response

Steps to reproduce

  1. Open compose screen
  2. Switch to home screen or another app

Expected behavior

Don't crash

Actual behavior

App crashes

Logs

 java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType
    at com.tokenautocomplete.TokenCompleteTextView.reifyParameterizedTypeClass(TokenCompleteTextView.java:1337)
    at com.tokenautocomplete.TokenCompleteTextView.onSaveInstanceState(TokenCompleteTextView.java:1360)
    at android.view.View.dispatchSaveInstanceState(View.java:20929)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.ViewGroup.dispatchSaveInstanceState(ViewGroup.java:3981)
    at android.view.View.saveHierarchyState(View.java:20912)
    at com.android.internal.policy.PhoneWindow.saveHierarchyState(PhoneWindow.java:2165)
    at android.app.Activity.onSaveInstanceState(Activity.java:2273)
    at androidx.core.app.ComponentActivity.onSaveInstanceState(ComponentActivity.java:96)
    at androidx.activity.ComponentActivity.onSaveInstanceState(ComponentActivity.java:397)
    at com.fsck.k9.activity.MessageCompose.onSaveInstanceState(MessageCompose.java:624)
    at android.app.Activity.performSaveInstanceState(Activity.java:2197)
    at android.app.Instrumentation.callActivityOnSaveInstanceState(Instrumentation.java:1509)
    at android.app.ActivityThread.callActivityOnSaveInstanceState(ActivityThread.java:5758)
    at android.app.ActivityThread.callActivityOnStop(ActivityThread.java:5163)
    at android.app.ActivityThread.performStopActivityInner(ActivityThread.java:5129)
    at android.app.ActivityThread.handleStopActivity(ActivityThread.java:5194)
    at android.app.servertransaction.StopActivityItem.execute(StopActivityItem.java:43)
    at android.app.servertransaction.ActivityTransactionItem.execute(ActivityTransactionItem.java:45)
    at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:176)
    at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:97)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2211)
    at android.os.Handler.dispatchMessage(Handler.java:106)
    at android.os.Looper.loopOnce(Looper.java:201)
    at android.os.Looper.loop(Looper.java:288)
    at android.app.ActivityThread.main(ActivityThread.java:7894)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1009)

This is probably due to R8 stripping information we need to keep. (Debug builds don't crash)

@cketti cketti added the type: bug Something is causing incorrect behavior or errors label May 1, 2023
@cketti cketti self-assigned this May 1, 2023
@dsg18096
Copy link

dsg18096 commented May 1, 2023

I was about to submit a report that I think is probably the same as this. Since getting updated to 6.701 in the past couple days I can no longer reply to a message. I get a crash as soon as I hit send or if I try to attach something to the draft. Composing a message from scratch works OK unless I try to attach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something is causing incorrect behavior or errors
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants