OpenLauncherTeam / openlauncher

Customizable and Open Source Launcher for Android
Apache License 2.0
1.41k stars 413 forks source link

Opening app in Dock causes crash #527

Closed paddatrapper closed 3 years ago

paddatrapper commented 4 years ago

General Information

Description

Occasionally, when trying to open apps from the dock, OpenLauncher crashes with the following error

java.lang.NullPointerException: Attempt to read from field 'java.lang.String com.benny.openlauncher.model.App._packageName' on a null object reference

Log

Build version: 0.7.0 
Build date: 1979-11-30 02:00:00 
Current date: 2019-11-29 16:36:43 
Device: HUAWEI MAR-LX1M 

Stack trace:  
java.lang.NullPointerException: Attempt to read from field 'java.lang.String com.benny.openlauncher.model.App._packageName' on a null object reference
    at com.benny.openlauncher.activity.HomeActivity.onStartApp(HomeActivity.java:346)
    at com.benny.openlauncher.util.Tool.startApp(Tool.java:155)
    at com.benny.openlauncher.widget.AppItemView$Builder$1$1.run(AppItemView.java:192)
    at com.benny.openlauncher.util.Tool$4$1.run(Tool.java:109)
    at android.os.Handler.handleCallback(Handler.java:891)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:207)
    at android.app.ActivityThread.main(ActivityThread.java:7539)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:958)
cmtjk commented 4 years ago

I can confirm this issue with 7.2.0. Unfortunately, I found no way to reproduce this issue, but there were changes made recently to fix another problem (https://github.com/OpenLauncherTeam/openlauncher/commit/0f0f1e6f79957b64c51af78dfaa9623eabe8a849). So maybe this is fixed with next release.

paddatrapper commented 3 years ago

Seems this is now fixed, I haven't been able to reproduce the issue since the last release to FDroid