phonegap / phonegap-plugin-push

Register and receive push notifications
MIT License
1.94k stars 1.91k forks source link

Notifications are not arriving on iOS (App Store version) since update 2.3.0 #2857

Closed ghost closed 4 years ago

ghost commented 5 years ago

:ambulance: :apple: :arrow_up:

Hi everyone,

We are working on an Ionic project and we are using this plugin. The plugin and the notifications had been working perfectly until we updated to 2.3.0 version.

In one point, we had to update to 2.3.0 version because of iOS 13. In that iOS update, the token changed to something like this: {length=32,bytes=....}. Whit the 2.3.0 version that problem was fixed. However, another problem appeared.

Now, the plugin and the notifications are working perfectly in Android (development and production version) and iOS (BUT ONLY IN DEVELOPMENT VERSION).

Currently, the notifications are not arriving in the iOS App Store version. We already tried everything. Also, we checked all the certificates, identifiers and profiles, but all seems to be perfect (photos attached).

I hope all of you could help us. All options are welcome.

Regards.

NOTE: There is no problem with the server. Notifications are being sent correctly.

Expected Behaviour

Notifications arriving on iOS App Store version

Actual Behaviour

Notifications are not arriving on iOS (App Store version)

Platform and Version (eg. Android 5.0 or iOS 9.2.1)

iOS 13.2.2

Cordova CLI version and cordova platform version

cordova --version            8.0.0
cordova platform version ios              5.0.1

Plugin version

cordova plugin version | grep phonegap-plugin-push            2.3.0

Certificates, identifiers and profiles screenshots

1-Profiles 2-Identifiers 3-APNSDevelopment 4-APNSProduction 5-DistributionCert 6-DevelopmentCert 7-ProjectConfig

martin-richter-uk commented 5 years ago

I have a setting in azure notification hub that allows me to switch between sandbox and prod version. Maybe in your notification hub it is switched to sandbox (unsigned)?

ghost commented 5 years ago

Hi rychter. We already checked the server side and all is correctly. The weird aspect is that the notifications were working perfectly with the older plugin version.

zdm commented 4 years ago

Not work for me too. Don't know what is the problem, I didn't changed anything, just rebuilt app. Previously push notifications worked on ios and android, now only on android.

sammyrsvp commented 4 years ago

Not working for me either. Same as @zdm. Any one tried cordova version 9?

sammyrsvp commented 4 years ago

Tested 2.2.3 on iOS 13, I can see a popup window: would like to send you notifications with 2 buttons "Do not Allow" and "Allow" when the app is installed and running for first time. But on 2.3.0, there is no popup.

zdm commented 4 years ago

I recreated certificate, provisioning profile and APNS key - and is start working.

sammyrsvp commented 4 years ago

Hi @zdm thank you very much for your update. Did you receive a popup window when the app is installed an opened for the first time: "Would you like the app to send you notifications? 2 buttons and "

GroupeBEL commented 4 years ago

@judari any update of this ? we have the same problem and we didn't find a solution yet, we generate new certificates and provisioning profile ... and we use gateway.push.apple.com:2195 but it's not working :(

ghost commented 4 years ago

Hi everyone,

Yes, we managed to solve it. The problem was that we were creating the certificate using the add certificate option (see picture 1) and then we linked it to the identifier. This is not the way to do it, this can generate the issue that is in this blog. The correct way to generate the certificate is doing it from the identifier using the "Create Certificate" option (see picture 2 and 3). I hope this solution helps you.

Regards

Picture 1 Screen Shot 2020-02-24 at 11 05 41 AM

Picture 2 Screen Shot 2020-02-24 at 11 05 59 AM

Picture 3 Screen Shot 2020-02-24 at 11 06 13 AM

lock[bot] commented 4 years ago

This thread has been automatically locked.