readrops/Readrops

[Bug] App crashing on start after upgrading from 2.0 beta01

Closed this issue · 2 comments

Describe the bug
I cannot start the app after upgrading to the latest version (f-droid build), it immediately shows me a stack trace.

java.lang.IllegalArgumentException: Unknown account type
	at kotlin.UnsignedKt.toCredentials(SourceFile:31)
	at androidx.paging.ChannelFlowCollector.emit(SourceFile:32)
	at kotlinx.coroutines.flow.DistinctFlowImpl$collect$2.emit(SourceFile:763)
	at kotlinx.coroutines.flow.internal.SafeCollectorKt$emitFun$1.invoke(SourceFile:5)
	at kotlinx.coroutines.flow.internal.SafeCollector.emit(SourceFile:10)
	at kotlinx.coroutines.flow.internal.SafeCollector.emit(SourceFile:1)
	at kotlinx.coroutines.flow.FlowKt.emitAllImpl$FlowKt__ChannelsKt(SourceFile:130)
	at kotlinx.coroutines.flow.FlowKt__ChannelsKt$emitAllImpl$1.invokeSuspend(SourceFile:12)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(Unknown Source:8)
	at kotlinx.coroutines.DispatchedTask.run(Unknown Source:96)
	at androidx.work.Worker$2.run(SourceFile:32)
	at kotlinx.coroutines.scheduling.TaskImpl.run(Unknown Source:2)
	at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(SourceFile:96)

To Reproduce
Steps to reproduce the behavior:

  1. Open the app

Expected behavior
The app opens.

Environment information (please complete the following information):

  • Account type: FreshRSS
  • App version: 2.0
  • Android version: Android 14 (lineage)
  • Device type: Samsung galaxy S10e
  • Store: F-Droid
  • Stacktrace collected from crash screen

Additional context
Purging data & cache and re-adding the account works as expected.

Did you start using Readrops with first 2.0 beta? If yes, then it's a known issue and there is nothing you can do apart from wiping data and recreating your account, as stated in the release notes.

After wiping app data, uninstalling and installing app I get:

org.koin.core.error.InstanceCreationException: Could not create instance for '[Singleton:'android.content.SharedPreferences']'
	at org.koin.core.instance.InstanceFactory.create(SourceFile:185)
	at org.koin.core.instance.SingleInstanceFactory.create(SourceFile:5)
	at org.koin.core.instance.SingleInstanceFactory.get(SourceFile:7)
	at org.koin.core.scope.Scope.resolveInstance(SourceFile:109)
	at org.koin.core.scope.Scope.get(SourceFile:127)
	at com.readrops.app.MainActivity$onCreate$1.invokeSuspend(SourceFile:68)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(Unknown Source:8)
	at kotlinx.coroutines.DispatchedTask.run(Unknown Source:96)
	at kotlinx.coroutines.EventLoopImplBase.processNextEvent(SourceFile:141)
	at kotlinx.coroutines.JobKt.runBlocking(SourceFile:102)
	at com.readrops.app.MainActivity.onCreate(SourceFile:32)
	at android.app.Activity.performCreate(Activity.java:8960)
	at android.app.Activity.performCreate(Activity.java:8938)
	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1526)
	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3975)
	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4173)
	at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:114)
	at android.app.servertransaction.TransactionExecutor.executeNonLifecycleItem(TransactionExecutor.java:231)
	at android.app.servertransaction.TransactionExecutor.executeTransactionItems(TransactionExecutor.java:152)
	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:93)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2595)
	at android.os.Handler.dispatchMessage(Handler.java:107)
	at android.os.Looper.loopOnce(Looper.java:232)
	at android.os.Looper.loop(Looper.java:317)
	at android.app.ActivityThread.main(ActivityThread.java:8592)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:580)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
Caused by: javax.crypto.AEADBadTagException
	at android.security.keystore2.AndroidKeyStoreCipherSpiBase.engineDoFinal(AndroidKeyStoreCipherSpiBase.java:634)
	at javax.crypto.Cipher.doFinal(Cipher.java:2132)
	at com.google.crypto.tink.integration.android.AndroidKeystoreAesGcm.decryptInternal(Unknown Source:27)
	at com.google.crypto.tink.integration.android.AndroidKeystoreAesGcm.decrypt(SourceFile:6)
	at coil.network.RealNetworkObserver.read(SourceFile:42)
	at androidx.appcompat.widget.TooltipPopup.readMasterkeyDecryptAndParseKeyset(SourceFile:31)
	at androidx.appcompat.widget.TooltipPopup.build(SourceFile:63)
	at com.readrops.db.DbModuleKt$$ExternalSyntheticLambda0.invoke(SourceFile:512)
	at org.koin.core.instance.InstanceFactory.create(SourceFile:48)
	... 27 more
Caused by: android.security.KeyStoreException: Signature/MAC verification failed (internal Keystore code: -30 message: system/security/keystore2/src/operation.rs:852: KeystoreOperation::finish

Caused by:
    0: system/security/keystore2/src/operation.rs:428: Finish failed.
    1: Error::Km(r#VERIFICATION_FAILED)) (public error code: 10 internal Keystore code: -30)
	at android.security.KeyStore2.getKeyStoreException(KeyStore2.java:416)
	at android.security.KeyStoreOperation.handleExceptions(KeyStoreOperation.java:79)
	at android.security.KeyStoreOperation.finish(KeyStoreOperation.java:132)
	at android.security.keystore2.KeyStoreCryptoOperationChunkedStreamer$MainDataStream.finish(KeyStoreCryptoOperationChunkedStreamer.java:228)
	at android.security.keystore2.KeyStoreCryptoOperationChunkedStreamer.doFinal(KeyStoreCryptoOperationChunkedStreamer.java:181)
	at android.security.keystore2.AndroidKeyStoreAuthenticatedAESCipherSpi$BufferAllOutputUntilDoFinalStreamer.doFinal(AndroidKeyStoreAuthenticatedAESCipherSpi.java:396)
	at android.security.keystore2.AndroidKeyStoreCipherSpiBase.engineDoFinal(AndroidKeyStoreCipherSpiBase.java:626)
	... 35 more

Does it mean android is not deleting something?