expo: Location.getCurrentPositionAsync() sometimes never responds or takes a very long time to respond

šŸ› Bug Report

I have slow performance on iOS (14), using Expo App (simulator - 11 and real device - 6s) or Standalone (real device - 6s).

Tried to add accuracy to Lowest, but I had same issue.

Works fine on Android.

Environment - output of expo diagnostics & the platform(s) you’re targeting

Expo CLI 3.27.12 environment info:
    System:
      OS: macOS 10.15.7
      Shell: 5.7.1 - /bin/zsh
    Binaries:
      Node: 12.13.1 - ~/.nvm/versions/node/v12.13.1/bin/node
      Yarn: 1.22.5 - /usr/local/bin/yarn
      npm: 6.12.1 - ~/.nvm/versions/node/v12.13.1/bin/npm
      Watchman: 4.9.0 - /usr/local/bin/watchman
    Managers:
      CocoaPods: 1.9.3 - /usr/local/bin/pod
    SDKs:
      iOS SDK:
        Platforms: iOS 14.0, DriverKit 19.0, macOS 10.15, tvOS 14.0, watchOS 7.0
      Android SDK:
        API Levels: 28
        Build Tools: 30.0.2
        System Images: android-29 | Google Play Intel x86 Atom
    IDEs:
      Android Studio: 4.0 AI-193.6911.18.40.6626763
      Xcode: 12.0.1/12A7300 - /usr/bin/xcodebuild
    npmPackages:
      @expo/webpack-config: ^0.12.16 => 0.12.37 
      expo: ^39.0.3 => 39.0.3 
      react: 16.13.1 => 16.13.1 
      react-dom: 16.13.1 => 16.13.1 
      react-native: https://github.com/expo/react-native/archive/sdk-39.0.3.tar.gz => 0.63.2 
      react-native-web: ~0.13.14 => 0.13.14 
    npmGlobalPackages:
      expo-cli: 3.27.12
    Expo Workflow: managed

Reproducible Demo

import * as Location from 'expo-location';

async function getLocation() {
  const start = Date.now();
  await Location.getCurrentLocationAsync();
  console.log(Date.now() - start); // consistently around 10,100ms
}

Snack reproducible demo -> https://snack.expo.io/@rvieceli/expo-issue-10756

About this issue

  • Original URL
  • State: open
  • Created 4 years ago
  • Reactions: 32
  • Comments: 104 (13 by maintainers)

Most upvoted comments

@rvieceli I tried passing it balanced as value, and even that value worked for me, a higher value gave problems. This is my code now, including the request for permission to the user:

// Get permissions const { status } = await Permissions.getAsync(Permissions.LOCATION); if (status !== 'granted') { return; }

// Get location
const location = await Location.getCurrentPositionAsync({ accuracy: Location.Accuracy.Balanced, });

Try set accuracy low as below:

const location = await Location.getCurrentPositionAsync({ accuracy: isAndroid ? Location.Accuracy.Low : Location.Accuracy.Lowest, })

I set Location.Accuracy.Balanced, which caused long time to get location sometimes. Android does not support Lowest. Although accuracy is low, it was accurate enough, and able to get location much faster than before.

https://forums.expo.io/t/location-getcurrentpositionasync-takes-10-seconds/19714/3

This issue is stale because it has been open for 60 days with no activity. If there is no activity in the next 7 days, the issue will be closed.

don’t.

Hey @Victor-Ross and @faroutchris. šŸ‘‹

Using @IDjinn’s implementation as an example, I have implemented an alternative solution that even takes into account the operating system-based timeout:

import { getCurrentPositionAsync, LocationObject } from 'expo-location'
import { Platform } from 'react-native'

function delay(timeInMilliseconds: number) {
  return new Promise<null>((resolve) => {
    setTimeout(() => resolve(null), timeInMilliseconds)
  })
}

export async function getLocation() {
  const ANDROID_DELAY_IN_MS = 4 * 1000 // šŸ‘ˆ 4s
  const IOS_DELAY_IN_MS = 15 * 1000 // šŸ‘ˆ 15s

  const DELAY_IN_MS =
    Platform.OS === 'ios' ? IOS_DELAY_IN_MS : ANDROID_DELAY_IN_MS

  const MAX_TRIES = 3
  let tries = 1

  let location: LocationObject | null = null

  let locationError: Error | null = null

  do {
    try {
      location = await Promise.race([
        delay(DELAY_IN_MS),
        getCurrentPositionAsync({
          accuracy: LocationAccuracy.BestForNavigation,
          distanceInterval: 0,
        }),
      ])

      if (!location) {
        throw new Error('Timeout')
      }
    } catch (err) {
      locationError = err as Error
    } finally {
      tries += 1;
    }
  } while (!location && tries <= MAX_TRIES)

  if (!location) {
    const error = locationError ?? new Error('šŸ’£')

    throw error
  }

  return location
}

šŸ’” In the case of iOS it has taken about 12s to resolve the getCurrentPositionAsync promise, so the timeout needed to be longer.

This implementation has worked for me. In the case of Android, if it don’t succeed on the first try (because the getCurrentPositionAsync method never resolves), on the second try everything happens almost instantly.

Thank you for filing this issue! This comment acknowledges we believe this may be a bug and there’s enough information to investigate it. However, we can’t promise any sort of timeline for resolution. We prioritize issues based on severity, breadth of impact, and alignment with our roadmap. If you’d like to help move it more quickly, you can continue to investigate it more deeply and/or you can open a pull request that fixes the cause.

So it seems that this is not a bug, and the documentation mentions this (https://docs.expo.io/versions/latest/sdk/location/)… What I ended up doing is using getLastKnownPositionAsync(), which is fast, to get the map started and then running getCurrentPositionAsync() in the background to get the more accurate location. Not the most elegant solution, but helps out.

This issue is stale because it has been open for 60 days with no activity. If there is no activity in the next 7 days, the issue will be closed.

I also tested different SDK versions.

Using Precise Location as ON SDK37 -> 0.025 seconds SDK38 -> 0.035 seconds SDK39 -> 10.012 seconds SDK40 -> 10.013 seconds

Using Precise Location as OFF SDK37 -> 10.02 seconds SDK38 -> 10.015 seconds SDK39 -> 10.016 seconds SDK40 -> 10.022 seconds

Still a recurring issue for me even with low accuracy

I resolved it with the following patch to convert to FusedLocationProviderClient.getCurrentLocation.


diff -r a/expo-location/android/src/main/java/expo/modules/location/LocationHelpers.java b/expo-location/android/src/main/java/expo/modules/location/LocationHelpers.java
151,154c151
<     // we want just one update
<     locationRequest.setNumUpdates(1);
< 
<     locationModule.requestLocationUpdates(locationRequest, null, new LocationRequestCallbacks() {
---
>     locationModule.requestSingleLocation(locationRequest, new LocationRequestCallbacks() {
diff -r a/expo-location/android/src/main/java/expo/modules/location/LocationModule.java b/expo-location/android/src/main/java/expo/modules/location/LocationModule.java
26a27
> import com.google.android.gms.location.CurrentLocationRequest;
545a547,566
> 
>   void requestSingleLocation(final LocationRequest locationRequest, final LocationRequestCallbacks callbacks) {
>     final FusedLocationProviderClient locationProvider = getLocationProvider();
>     
>     try {
>       locationProvider.getCurrentLocation(
>         new CurrentLocationRequest.Builder()
>           .setPriority(locationRequest.getPriority())
>           .setDurationMillis(locationRequest.getIntervalMillis())
>           .build(),
>         null
>       )
>       .addOnSuccessListener(location -> callbacks.onLocationChanged(location))
>       .addOnFailureListener(exception -> callbacks.onLocationError(new LocationUnavailableException()));
> 
>       callbacks.onRequestSuccess();
>     } catch (SecurityException e) {
>       callbacks.onRequestFailed(new LocationRequestRejectedException(e));
>     }
>   }
diff -r a/expo-location/android/build.gradle b/expo-location/android/build.gradle
87c87
<   api 'com.google.android.gms:play-services-location:16.0.0'
---
>   api 'com.google.android.gms:play-services-location:21.0.1'

This changes the behavior of Location.getCurrentPositionAsync to return null on timeout. If the caller wants to retry, for example:

      let location = null;
      const retries = 2;
      for (let i = 0; i <= retries && location == null; i++) {
        location = await Location.getCurrentPositionAsync({
          accuracy: Location.Accuracy.High,
        });
      }

      if (location) {
      } else {
      }

The timeout comes from the interval based on the accuracy in LocationHelpers.buildLocationParamsForAccuracy:

  • ACCURACY_LOWEST: 10000
  • ACCURACY_LOW: 5000
  • ACCURACY_BALANCED: 3000
  • ACCURACY_HIGH: 2000
  • ACCURACY_HIGHEST: 1000
  • ACCURACY_BEST_FOR_NAVIGATION: 500

The Priority is also mapped from accuracy.

I had to upgrade the Play Services Location dependency and I don’t know what the implications of that are.

Same here, sometimes the method is stuck…

I confirm the workaround using Location.watchPositionAsync(options, callback) instead of Location.getCurrentPositionAsync is working which confirms there is most probably a problem with the getCurrentPositionAsync method.

With the same accuracy and same implementation in the app, watchPositionAsync gives precise location under a second on iPhone and getCurrentPositionAsync takes more than 10sec.

Location.installWebGeolocationPolyfill() await navigator.geolocation.getCurrentPosition(position => { const latitude = JSON.stringify(position.coords.latitude); const longitude = JSON.stringify(position.coords.longitude); reverseGeocode(position.coords); setCurrentLocation({ latitude, longitude }) return true; }, error => { console.log(ā€œerror using navigator current positionā€) }, { enableHighAccuracy: false, timeout: 2000, maxiumAge: 1000 })

this helps

@sk-phan @m-regragui Hi,bor. I use watchPositionAsyncorgetCurrentPositionAsync Can’t obtain precise positioning, with a difference of several hundred meters? Have you ever encountered it? Is there any solution? image

          const location1 = await Location.watchPositionAsync({ accuracy: Location.Accuracy.High }
          )

          const location2 = await Location.getCurrentPositionAsync({
            accuracy: Location.Accuracy.High
          })

In our case, the issue of getCurrentPositionAsync hanging seemingly indefinitely was much more prevalent on Android. It was like rolling the dice (especially on some devices): 50% of the time it would just hang. Thank you to everyone above for sharing your workarounds with setting timeouts and retries. We set ours to try again just once after 3 seconds, and after 3 more seconds revert to getLastKnownPositionAsync.

We’re very confused as to why this api can simply hang forever with no error, and why it doesn’t include documented options for timeouts.

This issue is still happening. Pretty surprised it has not been adressed. It used to work and now 10 seconds+ on ios to get a location whatever the accuracy is set

I am facing the same issue. Every time it takes more than 10 seconds in iOS to get location data. To prove the theory, I changed my library to @react-native-community/geolocation to get location and everything remains as it is. With @react-native-community/geolocation, I get response within a second. I am using expo-location 9.0.1

Sorry for pinging here again. We have added the retry functionality. However, on iOS the response continually takes a minimum of 10 seconds to resolve. Has anyone of you found a solution to this? Too afraid to try another library at this point. Thanks!

My experience here:

  • Bare RN project
  • "expo-location": "15.1.1"

This is more of an Android issue for me. I can pretty reliably reproduce getCurrentPositionAsync never resolving on Android. I’ve never seen the issue of it not resolving on iOS, but frequently takes about 10 seconds. It’s weird…I time the operation and iOS will consistently resolve in exactly 10005ms on separate calls. Not always though…on both platforms sometimes this call works great and quickly gives me the location…it’s very sporadic.

The workarounds detailed in this thread have helped - mainly building the timeout around the getCurrentPositionAsync call and retrying. I’m using getLastKnownPositionAsync to quickly get a location during startup, then following that up with an asynchronous getCurrentPositionAsync with timeout/retrying.

Thanks, @MattZ6! Yes, we are releasing your solution today! Hopefully, it works out!

Hey @Saad-Bashar! šŸ‘‹

In my case, the implementation suggested in this https://github.com/expo/expo/issues/10756#issuecomment-1483254287 completely fulfilled the needs of the application I’m working on. I even use it with maximum accuracy.

Since the problem is the promise never resolves (or rejects), a simple timeout solved my problems. The people here on the forum can complement the answer.

Folks, we have been struggling with getting the user location. Our key feature of the app is clock in and clock out based on user location. We need precise accuracy. A lot of the complaints are coming due to the location issue.

In our app first we tried with react-native-geolocation, then we moved to react-native-geolocation-service. (at that time most probably the community one was not in active development, but now the package has come back to life it seems) Finally we decided to include expo-sdk in our bare react-native app to use the expo-location module. However, this module is also having issues, sometimes the method getCurrentPositionAsync just never responds and in general it takes quite a long time to get the lat and long back.

May I please know from others, what did you do if you were in the same shoes as mine? Are you still using expo location with above workarounds or moved to a different package? We are also considering to purchase react-native-background-geolocation. Would be really helpful to get some insights. Thanks a lot!

I’m using this workaround to force a response when the method get stuck.

function handleGetCurrentPosition() {
    return new Promise<LocationObject>((resolve, reject) => {
      let shouldResolve = true;
      let timer: ReturnType<typeof setTimeout>;
      Location.getCurrentPositionAsync().then((res) => {
        if (shouldResolve) {
        //  If we get a response from the API, just return the resolved promise
          clearTimeout(timer);
          resolve(res);
        }
      });
      
      // If the response takes too long, we reject the promise to prevent being stuck forever
      timer = setTimeout(() => {
        shouldResolve = false;
        reject('error');
      }, 5000);
    });
  }

I wait 5 seconds to get some response from the API call and if I didn’t get one, I reject the promise.

I did something like that. See


const fetchGPSLocation = (): Promise<Location> => {
    return new Promise(async (resolve, reject) => {
        let location = null;
        let tries = 1;
        do {
            try {
                location = await Promise.race([
                    sleep(4_000),
                    Location.getCurrentPositionAsync({
                        accuracy: LocationAccuracy.Balanced,
                    })
                ]);

                if (location)
                    return resolve(location);

                tries++;
                console.log(tries + ' tentativa para pegar localização do celular...');
            } catch {
            }
        }
        while (location == null && tries < MAX_LOCATION_TRIES);

        return reject('Não foi possível obter a localização GPS.');
    });
}

Same issue here, but on Android. Got randomly stuck on ā€œawait getCurrentPositionAsync({})ā€.

Example of my code:

async function getGeolocationData(registeredAddress: AddressDataProps) {
   console.log('getGeolocationData - getCurrentPositionAsync');
   try {
     const location = await Location.getCurrentPositionAsync({
       accuracy: Location.Accuracy.High,
     });

     console.log('getGeolocationData - reverseGeocodeAsync');
     const reverseGeocodeText = await Location.reverseGeocodeAsync({
       latitude: location.coords.latitude,
       longitude: location.coords.longitude,
     });

Sometimes it works flawlessly, but every now and then I get stuck in the getCurrentPositionAsync( ), the other functions and console.logs never get called. Tried with low accuracy, with interval, but nothing seems to help with the inconsistencies.

Hey @maralihart, awesome!

My problem is also in production with standalone app.

Can you share with us our permissions, dependencies (only from expo) and your implementation if is different from expo documentation?

Thank you. have a nice day!

I’m 100% sure if is related, but after our test in SDK38, we got this error in sentry Cannot obtain current location: Error Domain=kCLErrorDomain Code=0 "(null)" We don’t have anything in QA sentry with SDK 39.

Hi, i’m facing almost the same issue, expo-location works fine for me in dev with Location.getCurrentPositionAsync() or Location.getLastKnownPositionAsync() but it doesn’t work on production.

I’m on SDK 49 and expo-location 16.1.0, i’ve tried many things including the solution of @sk-phan, or change the play-services-location version in the build.gradle to 20 or 21.0.1.

Nothing worked. I managed to get the error message that shows only on production:

Error: Encountered an exception while calling native method: Exception occurred while executing exported method getLastKnownPositionAsync on module Expo Location: Found interface com.google.android.gms.lo cation.FusedLocation ProviderClient, but class was expected (declaration of ā€˜com.google.android.gms.locati on.FusedLocation ProviderClient’ appears in /data/app/

I don’t know what to do anymore, i’m on free plan on Expo and i’ve done my 30 builds this month just to try to resolve this issue, if someone has an new idea, i would like to test it… next month 🤣

Hey folks, just a side note, if you’re not using LocationAccuracy.High on Android it might take longer to acquire location since the device is not using all sensors to fetch the location. More info here

@MattZ6 I’m not understanding why the increment should be outside the try/catch


do {

  try {

    location = await Promise.race([

      delay(DELAY_IN_MS),

      Location.getCurrentPositionAsync(locationOptions)

    ]);



    if (!location) {

      throw new Error("Timeout");  // <---------- if you are thrown an error here it will be caught in catch below I think.

    }

  } catch (err) {

    locationError = err as Error;

    tries += 1; // šŸ‘ˆ can't we increment here?

  } 

} while (!location && tries <= MAX_TRIES);

The overall pattern seems to work well though!

depends on you need whether you want to increase only when error or both situations(success,error)

Still facing the same issue on SDK ^49.0.6 with ā€œexpo-locationā€: ā€œ~16.1.0ā€ 😭. I’ve tried the timeout methods and it fails on all attempts and even calling getLastKnownPositionAsync returns null. The weird thing is that it worked flawlessly on a previous version of my app that used SDK 46 with ā€œexpo-locationā€: ā€œ~14.3.0ā€, and it was fast too. I’ll try and use react-native-geolocation-service and see if that’s any better.

I used react-native-geolocation-service in bare project is faster than expo-location https://github.com/Agontuk/react-native-geolocation-service/tree/master will expo team consider embed this package into expo location ?

this is my code I used from above comment and it much faster but still not faster than react-native-geolocation-service

import {
    LocationCallback,
    LocationObject,
    LocationPermissionResponse,
    PermissionResponse,
    getCurrentPositionAsync,
    getForegroundPermissionsAsync,
    getLastKnownPositionAsync,
    requestForegroundPermissionsAsync,
} from 'expo-location';
import { useEffect, useRef } from 'react';
import { translateSync } from '../i18n';
import useAppStateChange from './useAppStateChange';
import useLatestCallback from './useLatestCallback';
import { ToastAndroid } from 'react-native';

export const useCurrentLocation = ({
    maxRetry = 3,
    onLocationSuccess = () => {},
    onLocationError = () => {},
    onLocationPermissionDeny = () => {},
    enabledResumeFromBackground = false,
}: UseWatchPositionProps) => {
    const retriesRef = useRef(0);
    const onLocationCallbackSuccess = useLatestCallback<LocationCallback>(onLocationSuccess);
    const onLocationErrorCallback = useLatestCallback(onLocationError);
    const onLocationPermissionDenyCallback = useLatestCallback(onLocationPermissionDeny);

    const getLocation = async (): Promise<
        [location: LocationObject | null, locationError: unknown | null]
    > => {
        let location: LocationObject | null = null;
        let locationError: unknown;
        do {
            try {
                // make it race condition if the first one reached the result will return
                location = await Promise.race([getCurrentPositionAsync(), sleep(DELAY_IN_MS)]);
                ToastAndroid.show('RUN', ToastAndroid.SHORT);
            } catch (error) {
                locationError = error;
            } finally {
                retriesRef.current++;
                if (retriesRef.current === maxRetry) {
                    location = await getLastKnownPositionAsync();
                    alert(`GET FROM LAST ${retriesRef.current}`);
                }
            }
        } while (
            !(location?.coords?.latitude && location?.coords?.longitude) &&
            retriesRef.current <= maxRetry
        );

        // IF ERROR
        if (!location) {
            const error = locationError ?? new Error('Unable to get location šŸ’£');
            let results: LocationPermissionResponse;
            if ((error as { code: string })?.code === 'E_LOCATION_UNAUTHORIZED') {
                results = await requestForegroundPermissionsAsync();
                onLocationPermissionDenyCallback?.(results);
            }

            onLocationErrorCallback?.({
                ...error,
                code: (error as { code: string })?.code,
                message: translateSync('can_not_get_location'),
            });
            return [null, error];
        }

        //   SUCCESS return and callback
        onLocationCallbackSuccess?.(location);
        return [location, null];
    };

    const registerTaskLocation = async () => {
        let results: PermissionResponse;
        try {
            results = await getForegroundPermissionsAsync();
            if (!results.granted) {
                results = await requestForegroundPermissionsAsync();
            }
            if (!results.canAskAgain && !results.granted) {
                onLocationPermissionDenyCallback(results);
                return;
            }
            await getLocation();
        } catch (error) {}
    };

    useEffect(() => {
        registerTaskLocation();
    }, []);

    useAppStateChange({
        onResumeFromBackground: () => {
            if (!enabledResumeFromBackground) return;
            registerTaskLocation();
        },
    });

    return {
        refetch: getLocation,
    };
};

const sleep = (timeInMilliseconds: number) => {
    return new Promise<null>((resolve) => {
        setTimeout(() => resolve(null), timeInMilliseconds);
    });
};
const DELAY_IN_MS = 1500; // šŸ‘ˆ 1.5s
type UseWatchPositionProps = {
    maxRetry?: number;
    onLocationSuccess?: LocationCallback;
    enabledResumeFromBackground?: boolean;
    onLocationError?: (error: { code: string; message: string }) => void;
    onLocationPermissionDeny?: (result: LocationPermissionResponse) => void;
};

@findhumane be careful with play-services-location:21.0.1, it can freeze the entire app: https://github.com/mrmans0n/smart-location-lib/issues/285, this module uses io.nlopez.smartlocation:library:3.3.3

Just some feedback after we released the retry functionality. We have tracked the events from mix-panel. We have found out a lot of the location fetch succeeded on the 2nd and even on the 3rd attempt. At the same time we got a lot of location fetching errors. The error message is not fully visible but mostly it says something like this on android,

"{\"nativeStackAndroid\":[{\"lineNumber\":4,\"file\":\"LocationModule.java\",\"methodName\":\"getCurrentPositionAsync\",\"class\":\"jc.u\"},{\"lineNumber\":-2,\"file\":\"Method.java\",\"methodName\":\"invoke\",\"class\":\"java.lang.reflect.Method\"},{\"lineNumber\":8,\"file\":\"ExportedModu",...

@MattZ6 since other devs might land on your comment, can you please edit it?

I believe adding it on finally improves readability by a lot!

Hey @efstathiosntonas, nice catch! Ideally, the increment of the current attempt should be outside of the try/catch, or even in an finally block:

do {
  try {
    location = await Promise.race([
      delay(DELAY_IN_MS),
      Location.getCurrentPositionAsync(locationOptions)
    ]);

    if (!location) {
      throw new Error("Timeout");
    }
  } catch (err) {
    locationError = err as Error;
  } finally {
    tries += 1; // šŸ‘ˆ Here
  }
} while (!location && tries <= MAX_TRIES);

is anyone else getting a std::runtime_error: Tried to reject a promise more than once. on iOS among these lines: (it rejects on line 120)

https://github.com/expo/expo/blob/d3c15ee0b7dd3479e6a5927703ef55c90207ebb1/packages/expo-location/ios/EXLocation/EXLocation.m#L109-L121

I’m using the solution from @MattZ6 comment

@MattZ6 does this ever increment? Shouldn’t it stop execution on throw new Error?

if (!location) {
        throw new Error('Timeout')
      }
      tries += 1

the tries += 1 should be outside of the try/catch otherwise it infinite loops:

do {
      tries += 1;
      try {
        location = await Promise.race([
          delay(DELAY_IN_MS),
          Location.getCurrentPositionAsync(locationOptions)
        ]);

        if (!location) {
          throw new Error("Timeout");
        }
      } catch (err) {
        locationError = err as Error;
      }
    } while (!location && tries <= MAX_TRIES);

Same issue with getCurrentPositionAsync() getting stuck. It seems to help with using lower accuracy but it isn’t 100% bulletproof.

I’m using this workaround to force a response when the method get stuck.

function handleGetCurrentPosition() {
    return new Promise<LocationObject>((resolve, reject) => {
      let shouldResolve = true;
      let timer: ReturnType<typeof setTimeout>;
      Location.getCurrentPositionAsync().then((res) => {
        if (shouldResolve) {
        //  If we get a response from the API, just return the resolved promise
          clearTimeout(timer);
          resolve(res);
        }
      });
      
      // If the response takes too long, we reject the promise to prevent being stuck forever
      timer = setTimeout(() => {
        shouldResolve = false;
        reject('error');
      }, 5000);
    });
  }

I wait 5 seconds to get some response from the API call and if I didn’t get one, I reject the promise.

same issue here. I used to rely on only watchPositionAsync since that would also trigger on initial app launch. After upgrading to SDK 46, this does not seem to happen anymore. So now, on launch for first time, I have to use getCurrentPositionAsync({}) and that is taking 10 seconds. Creates a very unpleasant experience to the user. Android device seem to be faster, while iOS and Android emulators are slow. Any idea maybe how to force the watchPositionAsync to run on initial start maybe since that one is faster? Maybe set some small time interval first then increase it so you don’t get too many events?

Wanted to follow up here, any update? Same issue, looking for alternatives at the moment

Thanks friends

I followed the steps in the documentation as well as the lines stated above, but I still am stuck at ā€œWaitingā€ for the location, never receiving the value

@AdamJNavarro We discovery more things during the investigation.

When Precise Location is OFF, SDK 38 and 39 are very slow, if we turn ON works fine in SDK38, but SDK39 is slow.

image