OpenSeizureDetector / Android_Pebble_SD

The main OpenSeizureDetector Android App, that is published on the Android Play Store.
http://openseizuredetector.org.uk
GNU General Public License v3.0
9 stars 11 forks source link

Crash when returning from export activity after long screen off #184

Open AroonPro opened 2 months ago

AroonPro commented 2 months ago

Dear OpenSeizureDetector,

Application is just crashed, please check following error log for more details.

OpenSeizureDetector Crash Report by Graham Jones (using UCE Error handler by Rohit Surwase)

***** DEVICE INFO Brand: samsung Device: a54x Model: SM-A546B Manufacturer: samsung Product: a54xnaeea SDK: 34 Release: 14

***** APP INFO Version: 5.0.0a Installed On: 2024-02-11 16:45:28 Updated On: 2024-05-01 20:16:53 Current Date: 2024-05-02 03:53:23

***** ERROR LOG java.lang.NullPointerException: Attempt to invoke virtual method 'boolean uk.org.openseizuredetector.WebApiConnection.getEvents(uk.org.openseizuredetector.WebApiConnection$JSONObjectCallback)' on a null object reference at uk.org.openseizuredetector.LogManagerControlActivity.getRemoteEvents(LogManagerControlActivity.java:254) at uk.org.openseizuredetector.LogManagerControlActivity.initialiseServiceConnection(LogManagerControlActivity.java:231) at uk.org.openseizuredetector.LogManagerControlActivity.waitForConnection(LogManagerControlActivity.java:206) at uk.org.openseizuredetector.LogManagerControlActivity.access$000(LogManagerControlActivity.java:54) at uk.org.openseizuredetector.LogManagerControlActivity$1.run(LogManagerControlActivity.java:212) at android.os.Handler.handleCallback(Handler.java:958) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loopOnce(Looper.java:230) at android.os.Looper.loop(Looper.java:319) at android.app.ActivityThread.main(ActivityThread.java:8893) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:608) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)

END OF LOG

jones139 commented 1 month ago

Do you know if this occurs in V4.2.x as well? I haven't seen it before, but I don't use the Export Data function.

jones139 commented 1 month ago

It looks like the WebApiConnection was null for some reason - maybe we are doing things in onStart that should be done in onResume instead?