Traewelldroid / traewelldroid

Android app for @Traewelling public transport check-in service
https://traewelldroid.de
GNU Affero General Public License v3.0
74 stars 13 forks source link

Crash on 2.1.0-foss #258

Closed Kurty00 closed 1 year ago

Kurty00 commented 1 year ago

Describe the bug The app crashes the moment it's started.

To Reproduce Steps to reproduce the behavior:

  1. Start the app.
  2. App crashes.

Expected behavior I expect the app not to crash.

Smartphone (please complete the following information):

forenta commented 1 year ago

Same on Motorola Edge 20 with Android 13 stock.

jheubuch commented 1 year ago

Hi, thanks for your report. Since I don't collect any crash reports via the foss-build, can you provide any Crash Logs which you may have recorded?

Otherwise I need to do a further investigation :)

fyrk commented 1 year ago

Hi, these are the crash details provided by Android on my device:

type: crash
osVersion: google/bluejay/bluejay:13/TQ3A.230805.001/2023090600:user/release-keys
package: de.hbch.traewelling:122
process: de.hbch.traewelling
processUptime: 93 + 232 ms
installer: dev.imranr.obtainium

java.lang.NoClassDefFoundError: Failed resolution of: Lio/sentry/instrumentation/file/SentryFileInputStream$Factory;
    at de.hbch.traewelling.util.ExtensionsKt$readOrDownloadLineIcons$icons$1.invokeSuspend(Extensions.kt:201)
    at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
    at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
    at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:115)
    at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:100)
    at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684)
Caused by: java.lang.ClassNotFoundException: io.sentry.instrumentation.file.SentryFileInputStream$Factory
    ... 9 more
jheubuch commented 1 year ago

Thanks! This is helping me since I couldn't reproduce this behavior locally on my machine...

jheubuch commented 1 year ago

Ok, so for the moment I can't do more than catching errors and add more logging because this error is very weird. (Like, I disabled Sentry for foss-build, nowhere on the given code lines Sentry is used but the app tries to open a SentryFileInputStream because of wtf?!)

So I'll push a new release in a few minutes with more logging and it would be nice if you could capture the Logcat outputs for next version 2.1.1 and share it with me so I can have a chance of more investigation...

fyrk commented 1 year ago
Okay, so this is what I could capture with logcat, looks to me like it's still the same error that Android displays in its crash dialog... ```log 2023-09-18 12:11:27.058 1309-6665 ActivityTaskManager system_server I START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=de.hbch.traewelling/.ui.launcher.LauncherActivity bnds=[446,957][641,1179]} from uid 10104 2023-09-18 12:11:27.085 1309-6665 WindowManager system_server W Cannot find window which accessibility connection is added to 2023-09-18 12:11:27.094 702-702 Zygote pid-702 D Forked child process 5840 2023-09-18 12:11:27.095 1309-1505 ActivityManager system_server I Start proc 5840:de.hbch.traewelling/u0a200 for next-top-activity {de.hbch.traewelling/de.hbch.traewelling.ui.launcher.LauncherActivity} 2023-09-18 12:11:27.097 5840-5840 Zygote pid-5840 W Can't access app profile directory: /data_mirror/cur_profiles/0/de.hbch.traewelling 2023-09-18 12:11:27.105 5840-5840 bch.traewelling pid-5840 E Not starting debugger since process cannot load the jdwp agent. 2023-09-18 12:11:27.160 5840-5840 AndroidRuntime pid-5840 D >>>>>> START com.android.internal.os.RuntimeInit uid 10200 <<<<<< 2023-09-18 12:11:27.160 5840-5840 libc pid-5840 W Access denied finding property "ro.debuggable" 2023-09-18 12:11:27.153 5840-5840 bch.traewelling pid-5840 W type=1400 audit(0.0:722979): avc: denied { read } for name="u:object_r:userdebug_or_eng_prop:s0" dev="tmpfs" ino=310 scontext=u:r:untrusted_app:s0:c200,c256,c512,c768 tcontext=u:object_r:userdebug_or_eng_prop:s0 tclass=file permissive=0 app=com.android.statementservice 2023-09-18 12:11:27.157 5840-5840 bch.traewelling pid-5840 W type=1400 audit(0.0:722980): avc: denied { read } for name="u:object_r:odsign_prop:s0" dev="tmpfs" ino=243 scontext=u:r:untrusted_app:s0:c200,c256,c512,c768 tcontext=u:object_r:odsign_prop:s0 tclass=file permissive=0 app=com.android.statementservice 2023-09-18 12:11:27.157 5840-5840 bch.traewelling pid-5840 W type=1400 audit(0.0:722981): avc: denied { read } for name="u:object_r:userdebug_or_eng_prop:s0" dev="tmpfs" ino=310 scontext=u:r:untrusted_app:s0:c200,c256,c512,c768 tcontext=u:object_r:userdebug_or_eng_prop:s0 tclass=file permissive=0 app=com.android.statementservice 2023-09-18 12:11:27.163 5840-5840 AndroidRuntime pid-5840 I Using default boot image 2023-09-18 12:11:27.163 5840-5840 AndroidRuntime pid-5840 I Leaving lock profiling enabled 2023-09-18 12:11:27.163 5840-5840 libc pid-5840 W Access denied finding property "odsign.verification.success" 2023-09-18 12:11:27.163 5840-5840 libc pid-5840 W Access denied finding property "ro.debuggable" 2023-09-18 12:11:27.163 5840-5840 cutils-trace pid-5840 E Error opening trace file: No such file or directory (2) 2023-09-18 12:11:27.165 5840-5840 de.hbch.traewelling pid-5840 W ART APEX data files are untrusted. 2023-09-18 12:11:27.161 5840-5840 bch.traewelling pid-5840 W type=1400 audit(0.0:722982): avc: denied { getattr } for path="/apex/apex-info-list.xml" dev="tmpfs" ino=67 scontext=u:r:untrusted_app:s0:c200,c256,c512,c768 tcontext=u:object_r:apex_info_file:s0 tclass=file permissive=0 app=com.android.statementservice 2023-09-18 12:11:27.161 5840-5840 bch.traewelling pid-5840 W type=1400 audit(0.0:722983): avc: denied { lock } for path="/system/framework/arm64/boot.art" dev="dm-10" ino=1407 scontext=u:r:untrusted_app:s0:c200,c256,c512,c768 tcontext=u:object_r:system_file:s0 tclass=file permissive=0 app=com.android.statementservice 2023-09-18 12:11:27.232 5840-5840 de.hbch.traewelling pid-5840 D Time zone APEX ICU file found: /apex/com.android.tzdata/etc/icu/icu_tzdata.dat 2023-09-18 12:11:27.232 5840-5840 de.hbch.traewelling pid-5840 D I18n APEX ICU file found: /apex/com.android.i18n/etc/icu/icudt70l.dat 2023-09-18 12:11:27.250 5840-5840 libc pid-5840 W Access denied finding property "ro.debuggable" 2023-09-18 12:11:27.251 5840-5840 AndroidRuntime pid-5840 D Calling main entry com.android.internal.os.ExecInit 2023-09-18 12:11:27.252 5840-5840 Zygote pid-5840 D begin preload 2023-09-18 12:11:27.252 5840-5840 Zygote pid-5840 I Calling ZygoteHooks.beginPreload() 2023-09-18 12:11:27.261 5840-5840 Zygote pid-5840 I Preloading shared libraries... 2023-09-18 12:11:27.263 5840-5840 de.hbch.traewelling pid-5840 E Unable to find pattern file or unable to map it for am 2023-09-18 12:11:27.263 5840-5840 Zygote pid-5840 I Called ZygoteHooks.endPreload() 2023-09-18 12:11:27.271 5840-5840 Zygote pid-5840 I Installed AndroidKeyStoreProvider in 9ms. 2023-09-18 12:11:27.271 5840-5840 Zygote pid-5840 D end preload 2023-09-18 12:11:27.276 5840-5869 libc pid-5840 W Access denied finding property "qemu.sf.lcd_density" 2023-09-18 12:11:27.276 5840-5869 libc pid-5840 W Access denied finding property "qemu.sf.lcd_density" 2023-09-18 12:11:27.282 5840-5840 Compatibil...geReporter pid-5840 D Compat change id reported: 171979766; UID 10200; state: ENABLED 2023-09-18 12:11:27.282 5840-5840 Typeface pid-5840 I Preloading /system/fonts/Roboto-Regular.ttf 2023-09-18 12:11:27.282 5840-5840 Typeface pid-5840 I Preloading /system/fonts/RobotoStatic-Regular.ttf 2023-09-18 12:11:27.317 5840-5840 GraphicsEnvironment pid-5840 V ANGLE Developer option for 'de.hbch.traewelling' set to: 'default' 2023-09-18 12:11:27.318 5840-5840 GraphicsEnvironment pid-5840 V ANGLE GameManagerService for de.hbch.traewelling: false 2023-09-18 12:11:27.318 5840-5840 GraphicsEnvironment pid-5840 V Neither updatable production driver nor prerelease driver is supported. 2023-09-18 12:11:27.320 5840-5840 NetworkSecurityConfig pid-5840 D No Network Security Config specified, using platform default 2023-09-18 12:11:27.320 5840-5840 NetworkSecurityConfig pid-5840 D No Network Security Config specified, using platform default 2023-09-18 12:11:27.328 5840-5840 FilemojiCompat pid-5840 W init: No Emoji Pack list created. Using empty one 2023-09-18 12:11:27.328 5840-5840 FilemojiCompat pid-5840 D init: Using system default 2023-09-18 12:11:27.339 5840-5840 AppCompatDelegate pid-5840 D Checking for metadata for AppLocalesMetadataHolderService : Service not found 2023-09-18 12:11:27.345 5840-5840 de.hbch.traewelling pid-5840 E Invalid ID 0x00000000. 2023-09-18 12:11:27.357 5840-5840 AndroidRuntime pid-5840 D Shutting down VM 2023-09-18 12:11:27.357 5840-5840 AndroidRuntime pid-5840 E FATAL EXCEPTION: main Process: de.hbch.traewelling, PID: 5840 java.lang.NoClassDefFoundError: Failed resolution of: Lio/sentry/instrumentation/file/SentryFileInputStream$Factory; at de.hbch.traewelling.util.ExtensionsKt$readOrDownloadLineIcons$icons$1.invokeSuspend(Extensions.kt:204) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106) at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:115) at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:100) at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684) Caused by: java.lang.ClassNotFoundException: io.sentry.instrumentation.file.SentryFileInputStream$Factory at de.hbch.traewelling.util.ExtensionsKt$readOrDownloadLineIcons$icons$1.invokeSuspend(Extensions.kt:204)  at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)  at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)  at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:115)  at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:100)  at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584)  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793)  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697)  at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684)  2023-09-18 12:11:27.358 1309-10970 ActivityTaskManager system_server W Force finishing activity de.hbch.traewelling/.ui.launcher.LauncherActivity 2023-09-18 12:11:27.367 1309-1493 ActivityManager system_server I Showing crash dialog for package de.hbch.traewelling u0 2023-09-18 12:11:27.376 1309-1493 CoreBackPreview system_server D Window{8690b6f u0 Application Error: de.hbch.traewelling}: Setting back callback OnBackInvokedCallbackInfo{mCallback=android.window.WindowOnBackInvokedDispatcher$OnBackInvokedCallbackWrapper@a6a9926, mPriority=0} 2023-09-18 12:11:27.589 1309-1309 Accessibil...gerService system_server W wait for adding window timeout: 2679 2023-09-18 12:11:27.859 1309-1495 ActivityTaskManager system_server W Activity top resumed state loss timeout for ActivityRecord{a724884 u0 de.hbch.traewelling/.ui.launcher.LauncherActivity} t455 f}} 2023-09-18 12:11:27.865 1309-1495 ActivityTaskManager system_server W Activity pause timeout for ActivityRecord{a724884 u0 de.hbch.traewelling/.ui.launcher.LauncherActivity} t455 f}} 2023-09-18 12:11:27.887 1309-1496 InputManager-JNI system_server W Input channel object '50d68f0 Splash Screen de.hbch.traewelling (client)' was disposed without first being removed with the input manager! 2023-09-18 12:11:28.255 1309-7090 WindowManager system_server W Failed looking up window session=Session{f6d6c92 1784:u0a10108} callers=com.android.server.wm.WindowManagerService.windowForClientLocked:6050 com.android.server.wm.WindowManagerService.relayoutWindow:2293 com.android.server.wm.Session.relayout:253 2023-09-18 12:11:28.265 1309-7090 WindowManager system_server W Cannot find window which accessibility connection is added to 2023-09-18 12:11:28.272 1309-7090 WindowManager system_server W Failed looking up window session=Session{f6d6c92 1784:u0a10108} callers=com.android.server.wm.WindowManagerService.windowForClientLocked:6050 com.android.server.wm.WindowManagerService.removeWindow:2076 com.android.server.wm.Session.remove:230 2023-09-18 12:11:28.273 1309-7090 InputManager-JNI system_server W Input channel object 'Embedded{} (client)' was disposed without first being removed with the input manager! 2023-09-18 12:11:28.275 1309-7090 WindowManager system_server W Cannot find window which accessibility connection is added to 2023-09-18 12:11:28.277 1309-7090 WindowManager system_server W Failed looking up window session=Session{f6d6c92 1784:u0a10108} callers=com.android.server.wm.WindowManagerService.windowForClientLocked:6050 com.android.server.wm.WindowManagerService.removeWindow:2076 com.android.server.wm.Session.remove:230 ```

If this doesn't help, I could also try building the app myself and debug on my device

jheubuch commented 1 year ago

That's very weird.. So if it's not bothering too much, you can always try debugging for yourself.

jheubuch commented 1 year ago

Ok, I could now reproduce it by running the release-build. With the debug-build it doesn't happen. 🙃

jheubuch commented 1 year ago

So well, I hope, I now have fixed it. If you could please confirm this by testing the next release? :)

fyrk commented 1 year ago

Seems to work now on my device :) The app starts and the nice line icons are finally visible! Many thanks!

jheubuch commented 1 year ago

No worries! Closing this as completed then :)