Location blue bar appears when not updating location
| Originator: | keithbsmiley | ||
| Number: | rdar://20764660 | Date Originated: | 30-Apr-2015 09:49 AM |
| Status: | Resolved | Resolved: | iOS 9 SDK and above with allowsBackgroundLocationUpdates |
| Product: | iOS SDK | Product Version: | 8.3 |
| Classification: | Other Bug | Reproducible: | Always |
When the background mode for locations is enabled, and the `CLLocationManager` has `requestWhenInUseAuthorization` access, the blue location bar appears after exiting the app. This occurs even when `stopUpdatingLocation` has been called in either `applicationDidEnterBackground` or `applicationWillResignActive`. Steps to reproduce: 1. Enable the background mode for location access 2. `requestWhenInUseAuthorization` 3. Start updating location 4. Stop updating location in either `UIApplicationDelegate` method 5. Put the app in the background Expected results: The blue location bar never appears since we are no longer accessing the user's location. Actual results: Note the blue location bar appears immediately and disappears after a few seconds. Notes: This combination of things makes sense when we don't always want to access the user's location in the background, but do other times (such as when the user wants directions). You can also reproduce this behavior using Google Maps on iOS.
Comments
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!
Resolved for iOS 9 and above with CLLocationManager's allowsBackgroundLocationUpdates property
Facing the exact same situation. Please let us know if you hear anything from Apple
https://stackoverflow.com/questions/27132698/ios8-blue-bar-is-using-your-location-appears-shortly-after-exiting-app
Example project: https://github.com/Keithbsmiley/radars/tree/master/LocationBlueBar