I'm working on an app and testing it with my partners via Apple's New TestFlight. I've never had issues with the old TestFlight system but now all of a sudden if I install the app via USB Cable & Xcode notifications come streaming in.
However if I install via Apple's TestFlight notifications never get delivered.
I'm using Parse for notifications and again have never had any problems. Anyone else have any issues or advice? Pretty frustrating.
Ok. Well it would seem that Apple's New TestFlight considers any version pushed "production". Therefore you must have a production certificate generated as well. Best best is to use an AdHoc Provisioning Profile which will use the production push certificate. Don't use a Development Provisioning Profile with a Development Push Certificate.
The more you know...
Related
I have tested push notifications as a developer account and it worked, But when I tried to put it on TestFlight for the testers to test it, it didn't show a push notification but the data is correctly received. So is there a kind of certificate that I need to generate for TestFlight or there is some issues in my profiles?
Push notification works when I install the app through XCode, but when I install it from test flight it is not working.
Problem is that your are using development APNS certificate.
For TestFlight users you need to send push notifications with production APNS (because when your are creating archive of your project, it's generated with release build settings). You can generate it in apple's developer portal: in your application settings page.
Yes, GhKaren is right. You have to use Production APNS when you upload app on itunesconnect and distribute it on Test-flight.
My Xcode has both development and distribution certificates that it manages by itself. I don't know how it picks either of the certificates when I build and run my project. I'm using Apple Push Notification Service in conjunction with Amazon. I ask for a device id from Apple and send it to Amazon where it can be used to publish notifications to Apple and then to my device. It seems that when I switch between debug and release mode, somehow a wrong certificate is used because Apple rejects the token id that I had just gotten from them and passed to Amazon. I've read that this could be due to the incompatibility between development and distribution environments on both platforms, meaning that both platforms should work in development or distribution.
I'm sure that the Amazon one is set to distribution because I manage it myself. But I don't know the token that I got from Apple has given to me by the development or the distribution certificate because Xcode manages it. Is there a way for me to know what certificate Xcode uses at any given time? And is there a way that I can specify it for Xcode? Thanks!
P.S. The app used to work fine in both development and distribution environments before, and I haven't made change in this regard other than switching between debug and release.
In the good old days of the original TestFlight I had a development certificate set for TestFlight releases and a production certificate for the live release of an app I'm working on. Never had any problems.
Since Apple took over I noticed the push notifications were failing and I discovered that the TestFlight sandbox on Apple only worked with the production certificate. This made no sense but worked. A week ago the notifications started failing once again (invalid token 8). Shifting to the development certificate did the job (the way it should have originally been on the TestFlight sandbox).
This morning the notifications are failing again and once again moving to the production certificate sent all the notifications.
Now to my question, is Apple making some changes that are affecting this or am I doing something wrong?
For users having the same issue. After some investigation I noticed that running an app from Xcode signs the app with a development certificate but installing the same release off Apple TestFlight does so with a production certificate. The notifications would fail on my device since I still had the Xcode version installed rather than the TestFlight release. For some reason I never installed the final version through TestFlight but left the one deployed from Xcode.
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
Me and another dev are working on an iOS app with Apple Push Notification Service. We were working on separate branches of the app and now that I have finished mine with the APNS all working, we were trying to merge and for him to build it into his code. The problem is that the APNS provisioning profile is tied to my account and device, so when he compiles and runs he does not have a valid profile to do the APNS.
Are there any options or workarounds to work on an app with another dev? I can't seem to find anyone else trying to do this so I assume it is either really easy or not possible. We both have individual dev accounts, but I think its crazy if we have to form a company and rebuy team dev accounts just to work on an app together...
you have to be in the same provisioning profile. Both Devices have to be in it too.
If you add a device to a provisioning profile this sometimes doesn't work directly, I have experienced, that you sometimes have to update the provisioning profile again without changeing something.
e.g.:
ProvisioningProfile_V1
your DeveloperAcc and your device
updating to ProvisioningProfile_V2
your DeveloperAcc and your device
other dev DeveloperAcc and his device
updating to ProvisioningProfile_V3 //(no changes)
your DeveloperAcc and your device
other dev DeveloperAcc and his device