UIBackgroundMode remote-notification doesn't work on iOS 7.1

Originator:alex
Number:rdar://17082448 Date Originated:2014/05/30
Status:Closed Resolved:Yes
Product:iOS Product Version:7.1
Classification:Serious Bug Reproducible:Always
 
Summary:
Sending a push notification with the "content-available" tag is supposed to wake up the app in the background and call "application:didReceiveRemoteNotification:fetchCompletionHandler". It works well on iOS 7.0.6, but not on iOS 7.1.1.

Steps to Reproduce:
1. Create an empty iOS application project. Launching it should display a plain white view.
2. Ask for push permissions when the app starts, and print the push token in the console.
3. In the target settings (Capabilities -> Background Modes) enable "Remote notifications".
4. In AppDelegate, implement "application:didReceiveRemoteNotification:fetchCompletionHandler". Make it change the window's background color to red and NSLog("Application did receive remote notification").
5. Run the app from Xcode (Product -> Run).
6. Close the app from Xcode (Product -> Stop).
7. Double press the Home button: the multitasking screenshot of the app shows a plain white view.
8. With a program such as nomad-cli (http://nomad-cli.com/), send a push notification to your device with the "content-available" tag (option -n with nomad-cli): the push notification should appear on the Home screen.
9. Double press the Home button and check the color of the multitasking screenshot.

Expected Results:
If the app was launched in the background and "application:didReceiveRemoteNotification:fetchCompletionHandler" was called, the multitasking screenshot should be red. Moreover, the console logs in the Xcode Organizer should display "Application did receive remote notification".

Actual Results:
On iOS 7.0.6, the multitasking screenshot is indeed red. Moreover, the console logs in the Xcode Organizer display the following logs:

May 30 16:50:14 iPad kernel[0] <Debug>: launchd[266] Container: /private/var/mobile/Applications/47E7DA84-E83A-4B43-B550-7D203921BD49 (sandbox)
May 30 16:50:14 iPad Test[266] <Warning>: Application did receive remote notification

---

On iOS 7.1.1, the multitasking screenshot stays white, and the console logs in the Xcode Organizer don't display anything.

Version:
iPhone 5: iOS 7.1.1 [11D201]. iPad 2: iOS 7.0.6 [11B651].

Notes:


Configuration:
iPhone 5 32GB AT&T, using WiFi. iPad 2 16GB, using WiFi.

Comments

False alert

This was a false alert. One of the devices I used for testing had background fetch disabled in the settings (Settings -> General -> Background App Refresh). I'm closing the issue.


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!