hms-react-native-plugin: App crashes when installed on iOS/non Huawei Android device

Hi! We integrated react-native-hms-push in our React Native app. It runs with no problems on Huawei phones, but the app crashes right when it starts if we run it on an iPhone or on other Android devices. There’s no error and no logs in metro. These are the versions of our dependencies (those that are relevant):

"@hmscore/react-native-hms-push": "^5.1.1-301",
"@react-native-agconnect/appmessaging": "1.2.0",
"@react-native-agconnect/core": "^1.2.0",
"@react-native-agconnect/crash": "1.2.0",
"react": "16.13.1",
"react-i18next": "^11.8.5",
"react-native": "0.63.4",

If I remove the react-native-hms-push dependency (and of course, the code that depends on it), the app starts. Anyone else running into this?

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 20

Most upvoted comments

Hi @ozcanozgur! Thanks for your response, but I do not want the library to be instantiated on Android devices that have google services capabilities. We only need the library on Huawei devices which no longer support Firebase Push notifications due to not having google services. So basically, if the phone doesn’t have HMS core and hms services, the library shouldn’t be used