-
-
Notifications
You must be signed in to change notification settings - Fork 361
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
huge latency #254
Comments
This is by no means enough information to determine if there is an issue. What platform (iOS/Android/Windows), platform version, plugin version, specific plugin functions are you testing? What do you mean by "GPS detection" and "GPS to embark"? |
Ok so Android,samsung s7 ( haven't tested on iOS yet ) cordova.plugins.locationAccuracy.canRequest returns 0 instead of 1 ifI try to do cordova.plugins.locationAccuracy.request even if canRequest = 0 |
Also in my config.xml I have but the thing is that everything was working just fine before and now it is not. |
The functions in the
As you can see from the commit history for
As the documentation states for canRequest(): "On Android, this will return true if the app has authorization to use location." I.e. this bears no relation to whether your phone gps is activated
This is to be expected if you call Note you need to also ensure appropriate permissions are added to the AndroidManifest.xml - see here |
Thank you for your reply. |
Probably Phonegap Build. When using remote build solutions such as this, you have no idea what they've changed in the build environment. If you're using |
I tested on a friend's iPhone and it is working just fine. So it must be an android compiling problem |
The location accuracy plugin works completely differently on iOS and would not rely on |
I am not using in my config.xml But I am using this |
I'd highly recommend moving to a local build environment instead of Phonegap Build as it puts you in complete control of your build environment. You can debug the Cordova app running inside the Webview using Chrome Dev Tools and the native plugin using Android Studio. |
I completely understand, and it starts to get on my nerves to be honest. |
Sorry to bother you again I did some digging, and I am still stuck on android.I have done a blank app with just the geolocation Can you confirm that what I do is correct ?
|
Also I have cloned your project https://github.com/dpa99c/cordova-plugin-request-location-accuracy-example.git and installed it, and it is not working. even when I switch on/off location. request location and it does nothing. |
Presumably you tried building it with Phonegap Build which will not work because the example project uses a Phonegap Build (like other "cloud" build services) is a 2nd class build enviroment compared with building locally, where you have full control of the source code and build environment.
No, it's not. By calling As I said above, you need to manually request run-time authorisation via the diagnostic plugin, something like this:
|
Good morning, Thank you so much for the code. before I launch the app I activate the gps localisation. then I have in this order Permission not requested : ( |
Found it, the new pgb compiling setup is no more including location permissions in the androidmanifest !!! Thanks again for the help, it's really appreciated. |
Closing this on the basis that the solution is you should not use Phonegap Build |
Hi,
I compiled my app few weeks ago and the GPS detection was working just fine.
I compiled yesterday and now it takes 2 to 3 min for the GPS to embark.
Can you look into the problem ?
Thanks
The text was updated successfully, but these errors were encountered: