zo0r / react-native-push-notification

React Native Local and Remote Notifications
MIT License
6.76k stars 2.05k forks source link

Scheduled local notifications are lost after reboot on Android #1590

Open juansebastianp21 opened 4 years ago

juansebastianp21 commented 4 years ago

I am getting an error when restarting the device in android, the scheduled notification is not displayed. I am running the example application that is in the repository and it presents the same problem.

Who knows if it is necessary to make another configuration so that the scheduled notifications are saved after restarting the device?

daheeahn commented 4 years ago

I faced the same problem. I hope this problem is solved soon. :)

yehiaemad commented 4 years ago

same here, any solutions. @Dallas62

felipeM0-zz commented 4 years ago

I was looking at some old problems, around 2016 there was already this issue being discussed in this repository, but today, 4 years later, the problem persists 😞

Dallas62 commented 4 years ago

Hi, Will try to look at this. Is it the same on iOS? I read somewhere that iOS doesn't store scheduled notifications after reboot. If it's the case, I'm not sure this is a good idea to solve it on Android.

felipeM0-zz commented 4 years ago

Hi, Will try to look at this. Is it the same on iOS? I read somewhere that iOS doesn't store scheduled notifications after reboot. If it's the case, I'm not sure this is a good idea to solve it on Android.

I do not know about the operation on IOS, I have only tested on Android. There are situations in which the feature is necessary, such as a periodic alarm or programmed reminders, apps to work completely without an internet connection (especially when the device has an automatic restart). I understand that remote notifications would make up for this lack that exists in local notification, but for apps that are intended to work without a connection, they simply become tedious if every time you need to enter to set the alarm again. Please check the possibility of implementing this. There are many people waiting for this and I know it will do the repository very well. Thanks for listening. 🙏🏻

Dallas62 commented 4 years ago

You can test changes on dev branch.

Please refer to the CHANGELOG for update instructions: https://github.com/zo0r/react-native-push-notification/blob/dev/CHANGELOG.md#unreleased

To install this version:

npm install zo0r/react-native-push-notification#dev

OR

yarn add zo0r/react-native-push-notification#dev

Make sure your build cache is cleaned.

daheeahn commented 4 years ago

Hi @Dallas62 ! Thank you for always maintaining this library well. Are these bugs being fixed?

Dallas62 commented 4 years ago

Did you test changes mentioned in the changelog?

Asim13se commented 4 years ago

@daheeahn I can confirm that after upgrading the library version to 6.1.1 scheduled local notifications appears after device restart, without opening the app, Thanks @Dallas62

alxindtesa commented 3 years ago

The problem was solved ? for when the application restarts

Does anyone have an example to prove this? already with the update?

Thanks people

xdarkleonx commented 3 years ago

I tried on version 7.3.1 and scheduled local notifications not work after restart.

Dallas62 commented 3 years ago

Hi, If you want to be sure the notification arrives, it's recommended to use remote notifications. Unfortunately, each manufacturers implement custom battery saving strategies which blow away most of background processes/scheduled tasks. Regards