Issues with Push Notification iOS 10 - Notification Does Not Have User Content

We are facing several problems with push notifications on iOS 10.
The main problem is that registered devices do not receive push notifications in iOS 10 if the aps json value is empty. In our application, there is one case when the server sends push without an aps value , since we do not need any warnings / title / sound, but I think this causes a problem on iOS 10 (no problems on iOS 8/9).

I set the PersistentConnectionLogging profile suggested by Apple ( link here ) to see more logs during the data exchange between iOS and APNS.
When clicked without aps value , I can see this log:

Sep 26 11:11:52 Mat apsd(PersistentConnection)[86] Notice: 2016-09-26 11:11:52 +0200 apsd[86]: APSCourier: 0x1003127d0: Received message for enabled topic โ€˜com.app.bundleIdโ€™ with payload '{
    aps = {};
    action = init;
}
Sep 26 11:11:52 Mat SpringBoard(UserNotificationsServer)[57] <Error>: Ignoring notification with no content (com.app.bundleId): C2E3-4A9E
Sep 26 11:11:52 Mat SpringBoard(UserNotificationsServer)[57] <Info>: Not saving push notification to store C2E3-4A9E, error=Error Domain=UNErrorDomain Code=1401 "Notification has no user-facing content" UserInfo={NSLocalizedDescription=Notification has no user-facing content}

It seems that this error has been logged , but I cannot figure out if there is a problem with empty aps Json value or not.

Has anyone had a similar problem or knew that in iOS 10 the aps value needs to be filled with some warning / icon / sound in order to receive the push notification correctly?

ps: the application is located in the AppStore and was created with Xcode 7 based on the iOS 9 SDK; users who have updated iOS 10 have encountered this problem.

+4

Source: https://habr.com/ru/post/1655816/


All Articles