Cordova-plugin-local-notifications: Schedule Repeatedly Not Work

Created on 11 Jun 2016  ·  4Comments  ·  Source: katzer/cordova-plugin-local-notifications

I have a basic schedule:

LocalNotifications.schedule({
id: 1,
text: "Single Notification" + new Date(),
data: { test: 'this_is_a_test' },
icon: "res://notification/ic_notification",
every: 'hour'
});

After 2/3 notifications it stop to notify.
I'm using Ionic 2 and Android. How can I identify the problem?

Thanks in Advance.

bug android

Most helpful comment

I did another test with "minute" schedule:

LocalNotifications.schedule({
id: 1,
text: "Single Notification" + new Date(),
data: { test: 'this_is_a_test' },
icon: "res://notification/ic_notification",
every: 'minute'
});

The first 15 notificatons are right, the problem are the other: the notifications arrived:

  • every 5 minutes for the notifications [16 - 23]
  • every one hour for the notifications [24 - 28]
  • the notification 29 after 3 hours;
  • the notification 30 after 5 hours;
  • and the last ones arrived every ~ 5 minutes.

I'm using the version 0.8.4 of the plugin, Android 6.0.1, cordova 6.0.0.

What could be the problem?
Here the logs of the notifications:

0 Sat Jun 11 2016 20:00:49 GMT+200 ...
1 Sat Jun 11 2016 20:01:59 GMT+200 ...
2 Sat Jun 11 2016 20:02:42 GMT+200 ...
3 Sat Jun 11 2016 20:03:42 GMT+200 ...
4 Sat Jun 11 2016 20:04:42 GMT+200 ...
5 Sat Jun 11 2016 20:05:50 GMT+200 ...
6 Sat Jun 11 2016 20:06:42 GMT+200 ...
7 Sat Jun 11 2016 20:07:59 GMT+200 ...
8 Sat Jun 11 2016 20:08:42 GMT+200 ...
9 Sat Jun 11 2016 20:09:48 GMT+200 ...
10 Sat Jun 11 2016 20:10:50 GMT+200 ...
11 Sat Jun 11 2016 20:12:04 GMT+200 ...
12 Sat Jun 11 2016 20:12:42 GMT+200 ...
13 Sat Jun 11 2016 20:14:16 GMT+200 ...
14 Sat Jun 11 2016 20:14:42 GMT+200 ...
15 Sat Jun 11 2016 20:15:49 GMT+200 ...
16 Sat Jun 11 2016 20:20:50 GMT+200 ...
17 Sat Jun 11 2016 20:25:50 GMT+200 ...
18 Sat Jun 11 2016 20:30:50 GMT+200 ...
19 Sat Jun 11 2016 20:35:50 GMT+200 ...
20 Sat Jun 11 2016 20:40:50 GMT+200 ...
21 Sat Jun 11 2016 20:45:50 GMT+200 ...
22 Sat Jun 11 2016 20:50:50 GMT+200 ...
23 Sat Jun 11 2016 20:55:50 GMT+200 ...
24 Sat Jun 11 2016 21:00:51 GMT+200 ...
25 Sat Jun 11 2016 22:00:51 GMT+200 ...
26 Sat Jun 11 2016 23:00:51 GMT+200 ...
27 Sat Jun 12 2016 00:00:51 GMT+200 ...
28 Sat Jun 12 2016 01:00:52 GMT+200 ...
29 Sat Jun 12 2016 04:00:51 GMT+200 ...
30 Sat Jun 12 2016 09:00:52 GMT+200 ...
31 Sat Jun 12 2016 10:22:23 GMT+200 ...
32 Sat Jun 12 2016 10:25:52 GMT+200 ...
33 Sat Jun 12 2016 10:30:52 GMT+200 ...

Thanks in Advance.

All 4 comments

I did another test with "minute" schedule:

LocalNotifications.schedule({
id: 1,
text: "Single Notification" + new Date(),
data: { test: 'this_is_a_test' },
icon: "res://notification/ic_notification",
every: 'minute'
});

The first 15 notificatons are right, the problem are the other: the notifications arrived:

  • every 5 minutes for the notifications [16 - 23]
  • every one hour for the notifications [24 - 28]
  • the notification 29 after 3 hours;
  • the notification 30 after 5 hours;
  • and the last ones arrived every ~ 5 minutes.

I'm using the version 0.8.4 of the plugin, Android 6.0.1, cordova 6.0.0.

What could be the problem?
Here the logs of the notifications:

0 Sat Jun 11 2016 20:00:49 GMT+200 ...
1 Sat Jun 11 2016 20:01:59 GMT+200 ...
2 Sat Jun 11 2016 20:02:42 GMT+200 ...
3 Sat Jun 11 2016 20:03:42 GMT+200 ...
4 Sat Jun 11 2016 20:04:42 GMT+200 ...
5 Sat Jun 11 2016 20:05:50 GMT+200 ...
6 Sat Jun 11 2016 20:06:42 GMT+200 ...
7 Sat Jun 11 2016 20:07:59 GMT+200 ...
8 Sat Jun 11 2016 20:08:42 GMT+200 ...
9 Sat Jun 11 2016 20:09:48 GMT+200 ...
10 Sat Jun 11 2016 20:10:50 GMT+200 ...
11 Sat Jun 11 2016 20:12:04 GMT+200 ...
12 Sat Jun 11 2016 20:12:42 GMT+200 ...
13 Sat Jun 11 2016 20:14:16 GMT+200 ...
14 Sat Jun 11 2016 20:14:42 GMT+200 ...
15 Sat Jun 11 2016 20:15:49 GMT+200 ...
16 Sat Jun 11 2016 20:20:50 GMT+200 ...
17 Sat Jun 11 2016 20:25:50 GMT+200 ...
18 Sat Jun 11 2016 20:30:50 GMT+200 ...
19 Sat Jun 11 2016 20:35:50 GMT+200 ...
20 Sat Jun 11 2016 20:40:50 GMT+200 ...
21 Sat Jun 11 2016 20:45:50 GMT+200 ...
22 Sat Jun 11 2016 20:50:50 GMT+200 ...
23 Sat Jun 11 2016 20:55:50 GMT+200 ...
24 Sat Jun 11 2016 21:00:51 GMT+200 ...
25 Sat Jun 11 2016 22:00:51 GMT+200 ...
26 Sat Jun 11 2016 23:00:51 GMT+200 ...
27 Sat Jun 12 2016 00:00:51 GMT+200 ...
28 Sat Jun 12 2016 01:00:52 GMT+200 ...
29 Sat Jun 12 2016 04:00:51 GMT+200 ...
30 Sat Jun 12 2016 09:00:52 GMT+200 ...
31 Sat Jun 12 2016 10:22:23 GMT+200 ...
32 Sat Jun 12 2016 10:25:52 GMT+200 ...
33 Sat Jun 12 2016 10:30:52 GMT+200 ...

Thanks in Advance.

Is this still an issue? Its over six months old.

Is this still an issue? Its over six months old.

Sure. I used a workaround.

Please use v0.9-beta. Thanks

Was this page helpful?
0 / 5 - 0 ratings