You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 15, 2024. It is now read-only.
Android phones failes to fetch location sometimes. No errors are thrown and the awaited method call to GetLocationAsync() never returns.
When debugging the source code I find that the call to GetBestProvider in Geolocation.android.cs/PlatformLocationAsync method returns the passive location provider when the GPS provider is not available. This provider relies on other applications to fetch the location and does not actually initiate any request. I'm not a 100% sure that this is the cause, but relying on the passive provider to fetch could probably cause this if we are not running any other applications that are actively requesting locations themselves at the same time.
Bug report best practices: Submitting Issues
Description
Android phones failes to fetch location sometimes. No errors are thrown and the awaited method call to GetLocationAsync() never returns.
When debugging the source code I find that the call to GetBestProvider in Geolocation.android.cs/PlatformLocationAsync method returns the passive location provider when the GPS provider is not available. This provider relies on other applications to fetch the location and does not actually initiate any request. I'm not a 100% sure that this is the cause, but relying on the passive provider to fetch could probably cause this if we are not running any other applications that are actively requesting locations themselves at the same time.
https://developer.android.com/reference/android/location/LocationManager#PASSIVE_PROVIDER
Steps to Reproduce
Expected Behavior
Should return that no location could be found
Actual Behavior
Never returns
Basic Information