Cannot get requestWhenInUseAuthorization to work #519
Comments
I have just added it into viewDidLoad in my own view controller. I have the same problem using the weekend-picks-template and adding the same code there works too. |
@esisa Are you using the latest release? Can you submit some complete sample code that shows this problem? |
I am running weekend-picks-template-ios with no changes from the current master branch. I have updated to the latest XCode. Running on iOS7 simulators work just fine. Running it in iOS8 does not bring up the location prompt and the location button does not bring me to the location set in the simulator. It is probably some quirk with my setup, but I have no idea what it would be. |
Did you add the NSLocationWhenInUseUsageDescription to your info.plist? <key>NSLocationWhenInUseUsageDescription</key> <string>String shown in the alertview</string> |
I'm also having this issue. I have the NSLocationWhenInUseUsageDescription key on my info.plist I'm using MapBox 1.4.1 installed as a binary. |
Yes, I have added that. Espen
|
Which example app @joaosobrinho? |
@incanus The app in this link: https://github.com/mapbox/mapbox-ios-example |
This sounds line my issue as well. I am not using CLLocationManager directly, the RMMapView does it all and I call: In looking through the code for 1.1.4 in RMMapView i see the NSAssert // enable iOS 8+ location authorization API |
Broken for me too on iOS8+. Fortunately you can work around it with a dummy location manager
|
This should be working fine. Check that the |
That commit won't make any difference to my usage. I'm using NSLocationWhenInUseUsageDescription in the Info.plist as per original code. |
Does your code break on this section if running on iOS 8 @wasatchtechnology? |
When testing out the SDK I cannot get requestWhenInUseAuthorization to work. No prompt is shown to the user to accept getting the location. I have added the necessary strings to the info.plist file.
To get it working I had to manually add this code:
The text was updated successfully, but these errors were encountered: