Open nSimonFR opened 6 years ago
Switching to FCM solved my problem.
Also if it's of any use I managed to read something from the logs when it crashed:
java.lang.ClassCastException: com.google.firebase.iid.zzf cannot be cast to com.google.android.gms.iid.zzi
This is an issue with GCM I'll have to take a look at it but considering that GCM is deprecated as of 4/10/2018 and support will be removed on 4/10/2019.. I'm almost partial to removing GCM support..
Just thinking out loud
I think you should leave this in till 4/10/2019.
There are still some businesses were change is hard and were it takes a long time. Sad but true. Did you find a way to fix this yet?
Anyone using AWS's SNS on the back end is also stuck with GCM until Amazon adds support for FCM.
We're in the same boat as @tony-krnl. @calcazar it would he helpful to at least know if anything is being done to remedy this issue.
Here I agree with @calcazar if you need GCM support you have react-native-push-notification
original library and seeing that if you migrate you push sender to FCM it works perfectly with old users that have the GCM version maybe the GCM support is not that important. I'm switching to firebase in my app and did this approach.
The original library does not support push notifications for Android O+ which is only one of the many problems it has. So I do not think this is the best solution.
That's true, but if you keep your targetSdkVersion to 25 push notifications in Oreo devices work correctly. I know it's a hack but meanwhile this is not solved or you migrate to Firebase can be a temporal solution.
Apparently FCM is backwards compatible with GCM. Has anyone had any luck integrating with AWS SNS? fcm-with-aws-sns
@nSimonFR when you say 'Switching to FCM solved my problem' what do you mean by that exactly? Switching on the API or on the client, and following what guide?
I have also the same issue app crashes when push notification arrives and not displaying as well.
I think it is problem with android oreo (8.1)
Anyone have solution?
@RobinJayaswal I switched my client configuration to use FCM instead of GCM, following the README of the repo. I simply needed to activate the FCM API on Google Cloud Console, and there was plenty of guides that covered how to do that. There was no additional setup on the server as the APIs are practically the same (I'm using node-pushnotifications).
@nSimonFR can you please add a link to the README? Not sure which repo are you referring to.
After following the installation guide, I get this native error when receiving a Notification sent through FCM:
com.google.firebase.iid.zzf cannot be cast to com.google.android.gms.iid.zzi
Package version:
react-native-push-notification-ce@3.1.7
compileSdkVersion: 26
buildToolsVersion: '26.0.2'