I'm using a public iCloud database in my app, which works great and is up on the store.
On updating my app to a new version (with Xcode 7 on iOS9) I get a crash on the line :
CKContainer * container = [CKContainer containerWithIdentifier:@"iCloud.com.identifier"];
*** Terminating app due to uncaught exception 'CKException', reason: 'The application is missing required entitlement com.apple.developer.icloud-services'
This happens ONLY the first launch of the app after updating, and only on iOS9. After that first (update) launch, the app launches and iCloud works as expected.
I can recreate the crash consistently by downloading the current store version of the app, then running the updated app from Xcode 7.
If I do the same steps (download production app, and update) using iOS8, I do not have the same crash.
I'm guessing this is an iOS9 or Xcode 7 bug. Any ideas?
EDIT : This actually happens on the first launch of the app on iOS9, regardless of whether I'm updating or just first installing.
Go to https://developer.apple.com/system-extensions/ and click the link to request an entitlement. Apply for the DriverKit entitlement and specify the entitlements you need. Provide a description of the apps you'll use to support your hardware.
iCloud entitlements let you enable the use of iCloud data storage for your iOS or macOS app. You set iCloud entitlement values on a target-by-target basis in your Xcode project. Push notifications let your app alert the user even when your iOS or macOS app is not executing.
Toggling the iCloud Capability on and off seems to have fixed it.
Toggling iCloud didn't work for me. Reinstalling the app didn't work either. The problem seems to happen whenever I have break points enabled. If I turn these off it runs without any problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With