Adamantcheese / Kuroba

Kuroba - imageboard browser for Android
GNU General Public License v3.0
392 stars 29 forks source link

App crashes within seconds of startup #1413

Closed ghost closed 1 year ago

ghost commented 1 year ago

I've been having an issue lately where sometimes the app just crashes and I have to restart my phone to fix it and just hope it doesn't happen

Here's a screen recording of it happening: https://files.catbox.moe/mfbz8j.mp4

Tested on v4.13.6-643c5ece on a Google Pixel 6 Pro

Twinov commented 1 year ago

I've had this happen but not as consistently, maybe 1 in 20 times. Mine also doesn't last until phone restart, for me opening the app again works. Captured a stack trace:

2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.github.adamantcheese.chan.dev, PID: 16065
    java.lang.RuntimeException: java.lang.IllegalStateException: request == null
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$3(BackgroundUtils.java:129)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$pNU0C8CWI4bwVEA5oO2zwmNxvMc(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda1.run(Unknown Source:2)
        at android.os.Handler.handleCallback(Handler.java:938)
        at android.os.Handler.dispatchMessage(Handler.java:99)
        at android.os.Looper.loopOnce(Looper.java:201)
        at android.os.Looper.loop(Looper.java:288)
        at android.app.ActivityThread.main(ActivityThread.java:7839)
        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:1003)
     Caused by: java.lang.IllegalStateException: request == null
        at okhttp3.Response$Builder.build(Response.kt:324)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.execute(NetUtilsClasses.java:373)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.lambda$enqueue$0(NetUtilsClasses.java:359)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.$r8$lambda$eCsh4UsNtPorZmvx37B5pGJLb5g(Unknown Source:0)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall$$ExternalSyntheticLambda0.run(Unknown Source:4)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:463)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$4(BackgroundUtils.java:121)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$9rYhI88R5umxXjUeRlJcaj1Psyk(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda4.run(Unknown Source:6)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
        at java.lang.Thread.run(Thread.java:1012)
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: Unhandled exception:
    java.lang.RuntimeException: java.lang.IllegalStateException: request == null
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$3(BackgroundUtils.java:129)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$pNU0C8CWI4bwVEA5oO2zwmNxvMc(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda1.run(Unknown Source:2)
        at android.os.Handler.handleCallback(Handler.java:938)
        at android.os.Handler.dispatchMessage(Handler.java:99)
        at android.os.Looper.loopOnce(Looper.java:201)
        at android.os.Looper.loop(Looper.java:288)
        at android.app.ActivityThread.main(ActivityThread.java:7839)
        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:1003)
     Caused by: java.lang.IllegalStateException: request == null
        at okhttp3.Response$Builder.build(Response.kt:324)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.execute(NetUtilsClasses.java:373)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.lambda$enqueue$0(NetUtilsClasses.java:359)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.$r8$lambda$eCsh4UsNtPorZmvx37B5pGJLb5g(Unknown Source:0)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall$$ExternalSyntheticLambda0.run(Unknown Source:4)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:463)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$4(BackgroundUtils.java:121)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$9rYhI88R5umxXjUeRlJcaj1Psyk(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda4.run(Unknown Source:6)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
        at java.lang.Thread.run(Thread.java:1012)
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: ------------------------------
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: END OF CURRENT RUNTIME MESSAGES
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: ------------------------------
2022-11-09 20:43:23.054 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: Android API Level: 31
2022-11-09 20:43:23.054 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: App Version: Kuroba-dev/v4.13.6-643c5ece
2022-11-09 20:43:23.054 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: Phone Model: Google Pixel 6 Pro
2022-11-09 20:43:23.057 16065-16065/com.github.adamantcheese.chan.dev I/cheese.chan.de: System.exit called, status: 999
2022-11-09 20:43:23.057 16065-16065/com.github.adamantcheese.chan.dev I/AndroidRuntime: VM exiting with result code 999, cleanup skipped.
Adamantcheese commented 1 year ago

I've been having an issue lately where sometimes the app just crashes and I have to restart my phone to fix it and just hope it doesn't happen

Here's a screen recording of it happening: https://files.catbox.moe/mfbz8j.mp4

Tested on v4.13.6-643c5ece on a Google Pixel 6 Pro

This is more than likely #1411.

I've had this happen but not as consistently, maybe 1 in 20 times. Mine also doesn't last until phone restart, for me opening the app again works. Captured a stack trace:

2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.github.adamantcheese.chan.dev, PID: 16065
    java.lang.RuntimeException: java.lang.IllegalStateException: request == null
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$3(BackgroundUtils.java:129)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$pNU0C8CWI4bwVEA5oO2zwmNxvMc(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda1.run(Unknown Source:2)
        at android.os.Handler.handleCallback(Handler.java:938)
        at android.os.Handler.dispatchMessage(Handler.java:99)
        at android.os.Looper.loopOnce(Looper.java:201)
        at android.os.Looper.loop(Looper.java:288)
        at android.app.ActivityThread.main(ActivityThread.java:7839)
        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:1003)
     Caused by: java.lang.IllegalStateException: request == null
        at okhttp3.Response$Builder.build(Response.kt:324)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.execute(NetUtilsClasses.java:373)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.lambda$enqueue$0(NetUtilsClasses.java:359)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.$r8$lambda$eCsh4UsNtPorZmvx37B5pGJLb5g(Unknown Source:0)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall$$ExternalSyntheticLambda0.run(Unknown Source:4)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:463)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$4(BackgroundUtils.java:121)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$9rYhI88R5umxXjUeRlJcaj1Psyk(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda4.run(Unknown Source:6)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
        at java.lang.Thread.run(Thread.java:1012)
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: Unhandled exception:
    java.lang.RuntimeException: java.lang.IllegalStateException: request == null
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$3(BackgroundUtils.java:129)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$pNU0C8CWI4bwVEA5oO2zwmNxvMc(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda1.run(Unknown Source:2)
        at android.os.Handler.handleCallback(Handler.java:938)
        at android.os.Handler.dispatchMessage(Handler.java:99)
        at android.os.Looper.loopOnce(Looper.java:201)
        at android.os.Looper.loop(Looper.java:288)
        at android.app.ActivityThread.main(ActivityThread.java:7839)
        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:1003)
     Caused by: java.lang.IllegalStateException: request == null
        at okhttp3.Response$Builder.build(Response.kt:324)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.execute(NetUtilsClasses.java:373)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.lambda$enqueue$0(NetUtilsClasses.java:359)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall.$r8$lambda$eCsh4UsNtPorZmvx37B5pGJLb5g(Unknown Source:0)
        at com.github.adamantcheese.chan.core.net.NetUtilsClasses$NullCall$$ExternalSyntheticLambda0.run(Unknown Source:4)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:463)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.lambda$runWithExecutor$4(BackgroundUtils.java:121)
        at com.github.adamantcheese.chan.utils.BackgroundUtils.$r8$lambda$9rYhI88R5umxXjUeRlJcaj1Psyk(Unknown Source:0)
        at com.github.adamantcheese.chan.utils.BackgroundUtils$$ExternalSyntheticLambda4.run(Unknown Source:6)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
        at java.lang.Thread.run(Thread.java:1012)
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: ------------------------------
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: END OF CURRENT RUNTIME MESSAGES
2022-11-09 20:43:23.053 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: ------------------------------
2022-11-09 20:43:23.054 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: Android API Level: 31
2022-11-09 20:43:23.054 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: App Version: Kuroba-dev/v4.13.6-643c5ece
2022-11-09 20:43:23.054 16065-16065/com.github.adamantcheese.chan.dev E/Kuroba-dev | UNCAUGHT: Phone Model: Google Pixel 6 Pro
2022-11-09 20:43:23.057 16065-16065/com.github.adamantcheese.chan.dev I/cheese.chan.de: System.exit called, status: 999
2022-11-09 20:43:23.057 16065-16065/com.github.adamantcheese.chan.dev I/AndroidRuntime: VM exiting with result code 999, cleanup skipped.

I have no idea how this one managed to slip by me pretty obvious when you look at the code and I just forgot a line. Only happens when certain embedding calls were getting cancelled, notably cached embed information calls.