Search code examples
cloudkit

Getting lots of CloudKit errors (500) all of a sudden


Nearly everything my app does in CloudKit now returns this error:

<CKError 0x14ecff70: "Server Rejected Request" (15/2001); "Request failed with http status code 500">
(lldb) po [error userInfo]
{
    CKDHTTPHeaders =     {
        Connection = close;
        "Content-Length" = 0;
        "X-Apple-Request-UUID" = "F8E4C91A-5F72-4792-9F13-BB5FBB10BA8E";
        "X-Responding-Instance" = "ckdatabaseservice:32400203:mr11p24ic-ztbu11100101:8103:15B153:16274";
    };
    CKHTTPStatus = 500;
    NSDebugDescription = "CKInternalErrorDomain: 2001";
    NSLocalizedDescription = "Request failed with http status code 500";
    NSUnderlyingError = "<CKError 0x14d5af70: \"Unknown Error\" (2001)>";
}

Any ideas why this could be happening? I'm tempted to blame it on temporary CloudKit server issues (which is how I would want to interpret an error 500)...but I don't know if that's appropriate.


Solution

  • This is a bug on the iCloud server that's affecting your container. I've grabbed logs from that request and the server team will clean up your container soon. In the meantime you can use a different container name for testing.

    If you'd like to file a radar for this we can let you know when the container gets cleaned up.