react-native-geolocation icon indicating copy to clipboard operation
react-native-geolocation copied to clipboard

IOS background location tracking stops after 40 minutes.

Open Akhidha00 opened this issue 1 year ago • 7 comments

I want to track the device for more than 10 hours in IOS background(app is in minimised state).But the tracking ends in 40 minutes. Is there any solution for this? The code is: await Geolocation.watchPosition( (position) => { var userLat = position.coords.latitude; var userLon = position.coords.longitude; if(latitude != userLat && longitude != userLon){ getLocationAddress(userLat, userLon); } }, (error) => { checkPermission() }, { enableHighAccuracy: true, distanceFilter:500, fastestInterval: 300000, showsBackgroundLocationIndicator: true} // Optional configuration );

And the versions are: "@react-native-community/geolocation": "^2.0.2", "react-native": "0.64.2",

I am stuck with this.

Akhidha00 avatar May 17 '24 06:05 Akhidha00

the same issue

megabeehothanhminh avatar Aug 21 '24 07:08 megabeehothanhminh

iOS prevents the background task after some time.Thats why this happens.You may use other library that can handle this issue.

Akhidha00 avatar Aug 21 '24 08:08 Akhidha00

the same issue, do you have any suggest for other libraries? @Akhidha00

PhamQuyet1606 avatar Sep 08 '24 05:09 PhamQuyet1606

The react-native-background-geolocation library is good for tracking. It is free for iOS live builds, but requires payment for Android live builds. You can use the library in Android debug mode, but not in live mode without a paid license.

Akhidha00 avatar Sep 09 '24 03:09 Akhidha00

react-native-background-geolocation is a terrible package with a really rude maintainer with no real support. If you ask a question you get bullied instead of an answer. The whole package is a huge misunderstanding and misusing fitness permission for location tracking purposes. It slowed down our app, made a huge negative attempt on it. Avoid it at all costs if you listen to me...

petertoth-dev avatar Sep 17 '24 21:09 petertoth-dev

@petertoth-dev I have interacted with the dev and he is not rude, he just gets to the point and probably has to deal with a lot of unexperienced devs just trying out the lib without reading the docs.

wmonecke avatar Oct 29 '24 10:10 wmonecke

@wmonecke yes, so he is rude... if he has no time to communicate properly, hire someone who does... he is breaking the law with his "non refund" policy as well, he sells a half-ready, non-performant product for a price of a Jetbrains software license :))) It's a scam.

petertoth-dev avatar Oct 29 '24 18:10 petertoth-dev