Tiago Lira
Tiago Lira

Reputation: 2550

iOS 8 - notifications stopped working in new Ad Hoc version

There are many threads already about this infamous error:

no valid 'aps-environment' entitlement string found for application

But the difference is that for me it was working perfectly before, and now the problem showed up again.

We updated the project for iOS8 in Xcode 6, and we created a new Ad Hoc distribution profile (Xcode got rid of the old one somehow), installed the ad hoc build with Testflight as we had before.

I tried to check for any trouble:

Nothing else seems wrong until the 'aps-environment' error (when the device tries to register for notifications). Could the new AdHoc profile mess this up somehow? Anyone has any idea of what can be the conflict?

Upvotes: 1

Views: 1372

Answers (1)

Wonjae
Wonjae

Reputation: 309

Xcode 6 seems like automatically generate provisioning profile(XC Ad Hoc : ...) for you. When you try to export ipa for AdHoc, see what bundle id the provisioning profile is using. If the bundle id contains wildcard(*), it won't work for push notification.

In my case, I removed wildcard bundle id from my app ID list in certification center, and refreshed profiles from Xcode accounts settings. After that, Xcode generated AdHoc profile with full app ID, and push started working again in AdHoc version.

Upvotes: 1

Related Questions