I added push notifications to one of my apps using Parse about a month ago, and it went through the review process fine and was pushed as an update through the App Store. Since then, everything has been going fine I've been using the REST API to send the notifications to all users.
Yesterday, I added push notifications to one of my other apps, following more or less the same process, and was able to get them up and running (while I have not yet submitted the update to the App Store, I have set up the production push provisioning profile).
Today, push notifications for the former app in production stopped working; the pushes successfully send through Parse, and they are delivered to my test device, but they are delivered to my test device only. That is, no production apps are receiving push notifications.
I suspect it is something to do with provisioning profiles, but I don't know how to fix it. I've looked around and everything I could find was related to production vs. development provisioning profiles for the app having the issue, which is not the case here since it was already working in production up until this point.
I have no idea how to go about finding the source of this issue (let alone solving it); any ideas?
So, I think you can probably make use of the Parse platform to check whether the certificate you exported is valid or not. If that's valid, that means that you don't have problem on the exportation.
Then, go check the the App ID you create in the Apple Developer Program whether it's enabled the production version and match the identifier you set in Xcode. In the same time, check whether the provisioning profile is from that App Id. If so, go ahead and open Xcode.
When you deploy to your test device, remember to change to the release mode instead of development mode. Also, better to change the code signing manually.
If the problem is still existing, I think you can probably delete all of your provisioning profiles in Xcode and do the process again.
Related
I am using Firebase server to send Push Notification to Live App Store build. I in following situations:
I was getting notification some period of time and stop from day.
But, i am getting all Push on my iPhone(By App Store Build) but my clients not getting notification.
My Questions:
I got some Push on Device and stop now,Does it mean my .p12 certificates wrong?
2.I think i submitted build to App Store using Ad Hoc Provisioning profile this could cause issue to some devices to stop notification?
My server team using Python language to send Push something use of Lamda causing issue(Server Side)?
Is this DeviceToken/ FCM issue?
5.How to make work the notification to Live App Store build install by customer?
How to fix this? Any help will much much appriciated.
Generate new certificates, add them to firebase, fix them within the app ,submit new build.
1) The push certificate expires after a year. Have you been to the Apple provisioning portal to see if it is still valid? If not, regenerate new ones for use with the server. You do not need to rebuild the app.
2) There is only one type of build provisioning that can be submitted to the App store. You think Apple will not check what is being submitted? You cannot have submitted anything that is not intended to be submitted
3)How can we possibly speculate on your server code. If they changed something on the server then of course they could have broken something. Whats Lamba got to do with anything
4) If the push token becomes invalid and your app does not send the new one to the server then push would not work for whatever devices have stale tokens
5) How can this be answered when you have not yet determined the cause.
If push has suddenly stopped for every device then either the push certificate is invalid or the server code has changed and broken something.
If push has stopped for just some devices then its likely that either your app is not sending a new token to the server when the token changes, or it is but your server is ignoring it and using old tokens.
If push has never ever worked for an app store build (which you are positively sure is an app store build) then either your server is sending pushes on the sandbox environment and not the production environment, or apns is not enabled for production and neither your nor anybody in your company ever tested pushes with a production build and production push environment before submitting to the app store.
Ok, so I have an app that is in the app store. In development everything works fine I get all of the notifications that I send. I should mention that we are using Firebase for analyics and push notifications as we have a iOS and Android version of the app. Firebase account has both the correct development and correct production apns cert, the app's capabilities are set correctly to include push notifications and remote notifications in the background.
In the organizer window the entitlement for apns-environement is set to production whenever uploading to the app store or when exporting the app. Whenever the app is first installed and ran the alert to allow push notifications is shown. So my apns certs have to be configured correctly.
I am a working on contract for this company, just started 3 months ago, I would hate for these people to look at me in a bad light but I really don't know where the issue is. I am also using Xcode's automatic code signing option, with the correct provisioning profile and developer account signed in the Xcode on this mac.
Just went through this and I do not know if you solved this,
I turned push off and deleted the certs from apple dev center and created them all over again and this made everything work as it should.
I also had this line of code set to,
FIRInstanceID.instanceID().setAPNSToken(deviceToken as Data, type: FIRInstanceIDAPNSTokenType.sandbox)
I will change it to .prod when I push to the app store.
i have used app with ios8.0 SDK and created explicit app id which is enabled push notifications for development environment
I have create provision profile for explicit app id and added profile to Xcode and run the app , then device token is generating, by using NWpusher i have tested notifications. notifications are working fire.
If we build the app and created ipa and installing that ipa on same device, generating different device token, and by using that device token in NWpusher app notifications are not working
Here i have used only developer environment for notifications
You have to repeat the exact same procedure that you undertook for the development certificate and testing in Xcode, once again only now for the production environment.
Getting push notifications to work can be a real pain, thus it is important to take a structured approach. Your issue is actually quite common, people tend to think that once they got push running in dev mode, it'll work in production mode immediately. This is not the case.
I recommend you to go through Ray Wenderlich's Tutorial on Push and take it step by step. They are demonstrating the case with a dev certificate as well, but the in the end they state the following (and this part is very often overread, they should point it out more clearly):
When you are ready to release your app, repeat this process for the
production certificate. The steps are the same.
You need to generate certificate and environment for distribution to work
I'm fairly new and this was the first time i submitted an app.
So i have an app thats already in the app store. I had push notifications set up and it work when i tested it for the ad hoc distribution using the production certificate.
I did another provisioning profile for the app store and submitted it. Strangely after the app got approved some provisioning profiles disappeared . After being in there for awhile they came back but the push notification setting was turned off even the production ssl certificate for push notif was gone.
Now, Push notifications are not working.
Tried generating another ssl cert and the whole keychain exporting stuffs but it still doesnt work.
I don't know if the app, submitted has the profile with the push notification settings on.
Is it possible to add push notifications to that app? If not what is my best solution here?
No if the App submitted has not been signed with a Push Notifications Profile , then you pretty much can't do any thing about it, You may have to resubmit an entire new Version with a different Provisioning Profile with Push Notifications enabled,
Did you check the server you are trying to connect to when you send the push notifications?
Remember that there are more than 1 server :
ssl://gateway.push.apple.com:2195
ssl://gateway.sandbox.push.apple.com:2195
ssl://feedback.push.apple.com:2196
ssl://feedback.sandbox.push.apple.com:2196
It seems that some migration script went wrong on Apple's server. Your best bet would be to contact Apple support and explain your problem to them. May be they can do something for you.
Even after creating a new push notification certificate you would not be able to enable the push notification for the app already present on app store. Since the certificate is regenerated, you would need to update your profiles too and then use them to prepare a new version for app store.
I think the problem was that the devices that i tried had the app built on them from xcode. Because it worked for other devices that i never used xcode with. After removing all the related provision profile from the device itself, located in the settings menu of the phone, reinstall the app from the store then it started to work.
I had the Push thing done over with at Parse.com (It was working and all) and then I was asked to create an account on parse for the company and set them up so they can manage it on their own. Well, not realizing that there was a Export button on the website, I deleted the app on my account and created an account for them and added the app to their account. I added all of the correct Certs and updated the App and Client keys and it wouldn't send it,and On the Push Notifications tab, it will show that i have recipients (My test Devices) but when I hit send, it will say Done, but nothing will appear on my device. So, being not too smart, I deleted that app and recreated it on my account (Thinking there might be something wrong with the other account). Well now it won't even work on my account. I have created all new certs and everything and i can't figure out why it is not working.And again, On the Push Notifications tab, it will show that i have recipients (My test Devices) but when I hit send, it will say Done, but nothing will appear on my device. Help?
My thought about what it might be is that the device is remembering the APNS Permission from the old account, Could I be Right?
I ran into this a while back. For me it was the difference between developer builds and release builds. You'll see in Apple's provisioning portal that there are 2 push certificates you can set up for your app. One is for production release and the other is for developer testing. When you build your app for testing it automatically looks for the developer cert. When you do a release build it looks for the release cert.
So... Make sure you have uploaded the correct push certificate to Parse. In my case Parse would say that messages had been sent to devices but I never saw them come through because Parse was sending them to Apple with a certificate that did not match my particular build type.