Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash #90

Closed
toas-koas opened this issue Jun 21, 2023 · 3 comments · Fixed by #95
Closed

Crash #90

toas-koas opened this issue Jun 21, 2023 · 3 comments · Fixed by #95
Labels
bug Something isn't working
Projects

Comments

@toas-koas
Copy link

Describe the bug
After start from the phone the app is crashing

To Reproduce
Start the phone

Expected behavior
No crash

Device :

  • Device: pixel 2xl
  • OS: Android 13
  • App-version Version 0.5.1
  • Battery optimization [false]
type: crash
osVersion: google/lineage_taimen/taimen:13/TQ2A.230505.002/eng.emy.20230613.033103:user/release-keys
package: de.nucleus.foss_warn:27
process: de.nucleus.foss_warn

java.lang.RuntimeException: Unable to start receiver com.dexterous.flutterlocalnotifications.ScheduledNotificationBootReceiver: java.lang.RuntimeException: Missing type parameter.
	at android.app.ActivityThread.handleReceiver(ActivityThread.java:4312)
	at android.app.ActivityThread.-$$Nest$mhandleReceiver(Unknown Source:0)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2149)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:201)
	at android.os.Looper.loop(Looper.java:288)
	at android.app.ActivityThread.main(ActivityThread.java:7884)
	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:952)
Caused by: java.lang.RuntimeException: Missing type parameter.
	at g0.a.d(Unknown Source:26)
	at g0.a.<init>(Unknown Source:7)
	at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin$a.<init>(Unknown Source:0)
	at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.loadScheduledNotifications(Unknown Source:25)
	at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.rescheduleNotifications(Unknown Source:0)
	at com.dexterous.flutterlocalnotifications.ScheduledNotificationBootReceiver.onReceive(Unknown Source:38)
	at android.app.ActivityThread.handleReceiver(ActivityThread.java:4303)
	... 9 more

@toas-koas toas-koas added the bug Something isn't working label Jun 21, 2023
@DocSniper
Copy link

DocSniper commented Jun 27, 2023

Can confirm this issue.

OS: Android 13 (LineageOS 20)
App-version: 0.5.1 (F-Droid)

Process: de.nucleus.foss_warn, PID: 10537
java.lang.RuntimeException: Unable to start receiver com.dexterous.flutterlocalnotifications.ScheduledNotificationBootReceiver: java.lang.RuntimeException: Missing type parameter.
	at android.app.ActivityThread.handleReceiver(ActivityThread.java:4315)
	at android.app.ActivityThread.-$$Nest$mhandleReceiver(Unknown Source:0)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2152)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:201)
	at android.os.Looper.loop(Looper.java:288)
	at android.app.ActivityThread.main(ActivityThread.java:7918)
	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:936)
Caused by: java.lang.RuntimeException: Missing type parameter.
	at g0.a.d(Unknown Source:26)
	at g0.a.<init>(Unknown Source:7)
	at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin$a.<init>(Unknown Source:0)
	at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.loadScheduledNotifications(Unknown Source:25)
	at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.rescheduleNotifications(Unknown Source:0)
	at com.dexterous.flutterlocalnotifications.ScheduledNotificationBootReceiver.onReceive(Unknown Source:38)
	at android.app.ActivityThread.handleReceiver(ActivityThread.java:4306)
	... 9 more

@nucleus-ffm
Copy link
Owner

Thank you for the bug report. I was able to reproduce the problem myself and also found the solution. The problem can be solved if we add some proguards rules as mentioned here by the developer. I added the file and the crash seems to be fixed. A side effect seems to be that fosswarn triggers the next background task only after the defined frequency and not directly at startup. Before that, fosswarn seems to have restarted because of the crash, which also caused the background service to run directly. Maybe we can think about implementing a callback that manually triggers the background task after startup.

@nucleus-ffm nucleus-ffm added the fixed-but-not-yet-merged The issue is solved, but the fix has not yet been merged and published in the main branch label Sep 5, 2023
@nucleus-ffm nucleus-ffm added this to Done in 0.6.0 Sep 19, 2023
@HarriBuh
Copy link

Any news on this issue? I have the same (silent) crash on every boot.

@nucleus-ffm nucleus-ffm linked a pull request Oct 1, 2023 that will close this issue
@nucleus-ffm nucleus-ffm mentioned this issue Oct 1, 2023
@nucleus-ffm nucleus-ffm removed the fixed-but-not-yet-merged The issue is solved, but the fix has not yet been merged and published in the main branch label Oct 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
0.6.0
Done
Development

Successfully merging a pull request may close this issue.

4 participants