MaikuB / MaikuB/flutter_local_notifications

Issue on android 13 with android

Open
#2,139 13 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Dart
Stars
2.7k
Forks
1.6k
Avg merge
4d 8h
Merged PRs (30d)
4

Description

java.lang.RuntimeException: Unable to start receiver com.dexterous.flutterlocalnotifications.ScheduledNotificationReceiver: java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.Integer.intValue()' on a null object reference
E/AndroidRuntime(22930): at android.app.ActivityThread.handleReceiver(ActivityThread.java:4903)
E/AndroidRuntime(22930): at android.app.ActivityThread.-$$Nest$mhandleReceiver(Unknown Source:0)
E/AndroidRuntime(22930): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2420)
E/AndroidRuntime(22930): at android.os.Handler.dispatchMessage(Handler.java:106)
E/AndroidRuntime(22930): at android.os.Looper.loopOnce(Looper.java:226)
E/AndroidRuntime(22930): at android.os.Looper.loop(Looper.java:313)
E/AndroidRuntime(22930): at android.app.ActivityThread.main(ActivityThread.java:8762)
E/AndroidRuntime(22930): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(22930): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:604)
E/AndroidRuntime(22930): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1067)
E/AndroidRuntime(22930): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'int java.lang.Integer.intValue()' on a null object reference
E/AndroidRuntime(22930): at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.setSmallIcon(FlutterLocalNotificationsPlugin.java:462)
E/AndroidRuntime(22930): at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.createNotification(FlutterLocalNotificationsPlugin.java:363)
E/AndroidRuntime(22930): at com.dexterous.flutterlocalnotifications.FlutterLocalNotificationsPlugin.showNotification(FlutterLocalNotificationsPlugin.java:1236)
E/AndroidRuntime(22930): at com.dexterous.flutterlocalnotifications.ScheduledNotificationReceiver.onReceive(ScheduledNotificationReceiver.java:61)
E/AndroidRuntime(22930): at android.app.ActivityThread.handleReceiver(ActivityThread.java:4894)
E/AndroidRuntime(22930): ... 9 more
D/CompatibilityChangeReporter(22930): Compat change id reported: 194532703; UID 10872; state: ENABLED
I/Process (22930): Sending signal. PID: 22930 SIG: 9

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The stack trace points to FlutterLocalNotificationsPlugin.java, especially setSmallIcon, createNotification, and showNotification, with ScheduledNotificationReceiver.java as the entry point. Start by reproducing a scheduled notification on Android 13 and trace the null value through these calls. Done means the receiver completes without the reported NullPointerException.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, flutter, java
Domain
mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.