Not receiving CloudKit push notifications for Custom Record Zone on the Mac
I’ve setup a custom zone subscription to receive (silent) push notifications from my custom record zone. Everything works fine on my iOS devices but I’m not able to receive the notifications on my Mac.
To register the notifications I’m registering the notification type in
[[NSApplication sharedApplication] registerForRemoteNotificationTypes:NSRemoteNotificationTypeNone];
(Tried the other types with the same result)
is then called with a valid token. Everything seems fine but when the custom zone registers changes, I receive no notification and
is not called. I’ve also tried to set the alert body to an empty string like this:
CKNotificationInfo *info = [[CKNotificationInfo alloc] init]; info.alertBody = @""; info.shouldSendContentAvailable = YES;
but it didn’t work either. When I set a string as the alert body (and register the appropriate notification type) I also get a notification with that body in the top right corner but application:didReceiveRemoteNotification: is not called.
Hope you can help me. Thanks!
2 Solutions Collect From Internet About “Not receiving CloudKit push notifications for Custom Record Zone on the Mac”
I think it’s fixed with macOS Sierra. Working for me now.
Oh wow: just noticed that I (!) asked this question 1,5y ago. 🙂
Simply extracting the correct solution from one of the shared links: If you use a CKNotificationInfo for your alerts, didReceiveRemoteNotification will NOT be called on the Mac until and unless you set CKNotificationInfo.soundName to an empty string! This looks like a bug only in OS X (10.10 & 10.11 so far) but can be worked around by this simple change.
- How to convert an Int into NSData in Swift?
- Opening tel: links from UIWebView
- CGContextDrawImage crashes
- Reduce array to set in Swift
- Check if class conforms to protocol
- Xcode 9: Provisioning profile is Xcode managed, but signing settings require a manually managed profile
- XCode Instruments Allocations: Look at Live Bytes or Overall Bytes?
- Why doesn't Xcode + Instrument Leaks detect this leak in simple C++ program
- How can i compress a video in ios using Bit Rate?
- Strange issue after upgrading to iOS 4.1 SDK
- Xcode 7 iOS 9 UITableViewCell Separator Inset issue
- Size class specifically for portrait 3.5 inch (iPhone 4S) XCode 6?
- Convert UIimage (take a picture) to NSData
- First letter in UiTextField lowercase
- How to cast sockaddr_in to sockaddr in swift