Kevin Preston
Posts: 0
Joined: Wed Oct 09, 2013 12:18 pm

GeoLocation bug?

I am trying to use the GeoLocation Service - I have set the request parameters as follows :-
maximumAge: 60000
timeout: 5000
enableHighAccuracy: true
watchPosition: true

If you invoke the service indoors (no satellites available) or with the GPS function on the device switched off you never receive the error event which should arrive after 'timeout' has expired.
If you use :-
navigator.geolocation.watchPosition(onSuccess, onError,{ maximumAge: 60000, timeout: 5000, enableHighAccuracy: true });

then you get the appropriate error raised.

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

GeoLocation bug?

Hello Kevin,

You need to set the handler of event "fail" for geolocation_service like to REST services yourself: http://devcenter.appery.io/documentat...

Kevin Preston
Posts: 0
Joined: Wed Oct 09, 2013 12:18 pm

GeoLocation bug?

Evgene,
Sorry perhaps I didn't explain what I meant properly.
The 'fail' event will fire as in your link but how do you find the reason for the failure eg GPS switched off or no satellite?

Kevin

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

GeoLocation bug?

Kevin,

Yes, for handler on event "fail" no options are passed, so there is no opportunity to clarify the details, but you can use the event "complete" in its handler parameters are passed.

Kevin Preston
Posts: 0
Joined: Wed Oct 09, 2013 12:18 pm

GeoLocation bug?

Evgene,
Could you give an example how to access the parameters as 'textStatus' shows as 'undefined'
Thanks,
Kevin

Kevin Preston
Posts: 0
Joined: Wed Oct 09, 2013 12:18 pm

GeoLocation bug?

Any update?

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

GeoLocation bug?

Hi Kevin,

Unfortunately, not yet. Working on it.

Kevin Preston
Posts: 0
Joined: Wed Oct 09, 2013 12:18 pm

GeoLocation bug?

OK thanks.

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

GeoLocation bug?

Hello Kevin,

It was misconception, sorry for this. You do can get detailed information in the handler of event "fail". Despite the fact that in the UI builder you can't see passed parameters, you still have access to three parameters jqXHR, textStatus and errorThrown. They contain details of the error.

Kevin Preston
Posts: 0
Joined: Wed Oct 09, 2013 12:18 pm

GeoLocation bug?

Thanks, I'll try it.

Kevin

Return to “Issues”