The simulator is in iOS8.1 and I am using Xcode 6.1.1.
I have tried solutions from several different sources:
And nothing works. My setup:
Rights and opportunities:


The code:
dispatch_async(dispatch_get_global_queue (DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^(void) {
NSURL *myContainer = [[NSFileManager defaultManager] URLForUbiquityContainerIdentifier:nil];
if (myContainer != nil) {
NSString *filePath = [NSString stringWithFormat:@"%@/%@", myContainer.path, ARCHIVE_FILE_NAME];
self.journal = [NSKeyedUnarchiver unarchiveObjectWithFile:filePath];
if (self.journal == nil)
[self initJournalFromLocalStorage];
else
[self.journal validateUserDefines];
self.journal.cloudURL = myContainer;
dispatch_async (dispatch_get_main_queue (), ^(void) {
});
}
});
My Apple ID has iCloud enabled for development and distribution; and I tried to create and upload a new training profile.
I also tried changing iCloud. $ (CFBundleIdentifier) ββfor $ (TeamIdentifierPrefix) $ (CFBundleIdentifier) ββin rights.
No matter what I do, the URLForUbiquityContainerIdentifier always returns nil. Any help is appreciated!