I'm using the following code on WatchOS 3, in an attempt to store data on CloudKit directly from the WatchKit Extension's InterfaceController class:
let recordID = CKRecordID(recordName: Utility.convertToID(Date()))
let usersContainer = CKContainer.default()
usersContainer.accountStatus(completionHandler: { accountStatus, error in
if accountStatus == CKAccountStatus.noAccount {
// Always True
}
})
Using the iOS 10 simulator and paired WatchOS 3 simulator, I am always returned with noAccount from the CKContainer.accountStatus() completion handler.
This does not happen on my physical device.
Am I forgetting something, or is this an issue others have encountered?