-
Notifications
You must be signed in to change notification settings - Fork 81
Description
Description
When synchronizing tables with a large number of records (e.g., LocationPoint with GPS coordinates), CloudKit sync fails with a "Limit Exceeded" error because CloudKit has a hard limit of 400 items per request.
Caught error: <CKError 0x1310f9230: "Limit Exceeded" (27/1020);
"Your request contains 1360 items which is more than the maximum number of items in a single request (400)">:
SQLiteData CloudKit Failure
This occurs during initial sync or when a large batch of records needs to be synchronized.
Expected behavior
SyncEngine should automatically chunk large batches of records into groups of 400 or fewer items per CloudKit request, similar to how batch operations are handled in the application layer.
Actual behavior
SyncEngine attempts to sync all pending records in a single CloudKit request, which fails when the count exceeds 400 items.
Reproducing scenario
- Create a table that accumulates many records
- Enable iCloud sync with
SyncEnginefor that table - Record hundreds of location points locally
- Trigger sync
Result: CloudKit sync fails with "Limit Exceeded (27/1020)" error
Suggested solution
Add automatic chunking in SyncEngine to split large batches into 400-item chunks before sending to CloudKit, similar to:
Destination operating system
iOS 26
Xcode version information
Xcode 26.2