2

I implemented the React Native push notifications library today inside our app. It was working fine before, and now it's working on Android debug mode and Android 11 (tested on both phone and emulator), but it's crashing on Android 14. I see the home screen and then it crashes. It works fine on Android 11.

I tried to remove the library react push notifications then it starts working on Android 14 but after installing it, it work's on Android 11 but not in 14

2
  • Install build and then use adb logcat to check why it's crashing. See also https://stackoverflow.com/questions/3643395/how-to-get-android-crash-logs. Commented Apr 28, 2024 at 16:52
  • If you're using react-native 0.73+, the android part of the project will now use targetSdkVersion 34 (Android 14) - This requires changes to the implementation of registerReceiver which now requires flags to set exported true/false. react-native-push-notifications hasn't had an update since 2021 so will likely not include proper Android 14 support. You'll need to manually patch the change or use a more up-to-date RN push library (notifee for example). Commented Jul 16, 2024 at 10:32

1 Answer 1

0

android 14 need to manually request permission for EXACT alarms.

see https://github.com/zo0r/react-native-push-notification/issues/2256

and https://github.com/zoontek/react-native-permissions/issues/795

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.