Removing adding android platform broke navigator.geolocation.GetCurrentPosition


#1

In order to combat a problem in the build process (Could not GET ‘https://repo1.maven.org/maven2/com/android/tools/build/gradle/maven-metadata.xml’ (peer not authenticated)),

I removed (ionic platform remove android) the android platform and added it back in again (ionic platform add android).

After that I was able to successfully rebuild the project. But it seems like removing and re-adding the android platform somehow broke navigator.geolocation.GetCurrentPosition. When called it immediately returns a POSITION_UNAVAILABLE (2) code.

Anyone knows what might be going on?


#2

Never mind - It was NOT removing / adding android that was the cause. It was apparently related to the initial problem I was trying to fix


#3

GAAAHH - It seems after all it was removing and re-adding the the android platform that caused it.

Has anyone else experienced this or have any idea where to start looking?

Your system information:

Cordova CLI: 6.1.1
Ionic Version: 1.2.4
Ionic CLI Version: 1.7.14
Ionic App Lib Version: 0.7.0
OS: Distributor ID: Ubuntu Description: Ubuntu 14.04.4 LTS
Node Version: v5.2.0

cordova-plugin-console 1.0.2 "Console"
cordova-plugin-device 1.1.1 "Device"
cordova-plugin-splashscreen 3.1.0 "Splashscreen"
cordova-plugin-statusbar 2.1.0 "StatusBar"
cordova-plugin-whitelist 1.2.1 "Whitelist"
ionic-plugin-keyboard 1.0.8 "Keyboard"
phonegap-plugin-push 1.6.1 “PushPlugin”

Ions, bower components, or addons installed:
ionic
ionic-platform-web-client


#4

Ok - finally got it into my thick head. Of course it blew away the locations permissions in AndroidManifest.xml.