Here's a snippet of code in which I'm modifying some records on a user's private CloudKit DB.
let op = CKModifyRecordsOperation(recordsToSave: recordsToModify, recordIDsToDelete: []) op.savePolicy = CKRecordSavePolicy.ChangedKeys op.modifyRecordsCompletionBlock = { saved, deleted, err in println("modified all ... \(saved.count) w err '\(err)' \(err != nil ? err.userInfo : [:])") } self.privateDB.addOperation(op) Νοrmally this works great:
modified all ... 284 w err 'nil' Optional([:]) But every now and then I get the following output:
modified all ... 0 w err '<CKError 0x7f9210e92840:"Zone Busy" (23/2029); "Zone busy">' Optional([NSDebugDescription: CKInternalErrorDomain: 2029, NSLocalizedDescription: Zone busy, NSUnderlyingError: <CKError 0x7f9210ea7dd0: "Unknown Error" (2029)>]) I'm assuming this is a hiccup of some sort on CloudKit's side of things - but how do I detect this? How should I handle it?