NSPersistentCloudKitContainer does not sync in background

I am currently testing the NSPersistentCloudKitContainer.
I have strictly followed the guidelines of the new documentation. Basically everything works as desired. I use the option NSPersistentStoreRemoteChangeNotificationPostOptionKey on the description to receive Updates from the remote data store. But the updates from the remote database are only delivered if the app is in the foreground. But I would like to update my widget based on a data change in the backend.

Does anyone has an idea how to solve this issues?

What i did so far:
  • Background Modes in Capabilities are enabled

  • Push Notifications are enabled

  • i called registerForRemoteNotifications

  • HistoryTracking and RemoteChange Option are enabled on the description of the PersistentStore

Syncing works in foreground ✅
Syncing does not work if App is in Background ❌

Code Block description?.setOption(true as NSNumber,
                               forKey: NSPersistentStoreRemoteChangeNotificationPostOptionKey)
        description?.setOption(true as NSNumber,
                               forKey: NSPersistentHistoryTrackingKey)
        
        container.viewContext.automaticallyMergesChangesFromParent = true
        container.viewContext.mergePolicy = NSOverwriteMergePolicy


Please file a bug report with a sysdiagnose from each of the involved devices. Thanks.
NSPersistentCloudKitContainer does not sync in background
 
 
Q