react-native-background-geolocation
react-native-background-geolocation copied to clipboard
Location tracking stops the working if the app is terminated.
Your Environment
- Plugin version: "^4.14.0"
- Platform: iOS or Android : Android
- OS version: Android 10 and 13
- Device manufacturer / model: Samsung M33
- React Native version (
react-native -v
): 0.64.2 - Plugin config
reset: true,
desiredAccuracy: BackgroundGeolocation.DESIRED_ACCURACY_HIGH,
distanceFilter: 10,
foregroundService: true,
stopOnStationary: false,
locationUpdateInterval: 6000,
fastestLocationUpdateInterval: 20000,
autoSync: true,
enableHeadless: true,
debug: false, // <-- enable this hear sounds for background-geolocation life-cycle.
logLevel: BackgroundGeolocation.LOG_LEVEL_VERBOSE,
stopOnTerminate: false, // <-- Allow the background-service to continue tracking when user closes the app.
startOnBoot: true, // <-- Auto start tracking when device is powered-up.
backgroundPermissionRationale: {
title: 'Allow Bookelu to access this device`s location even when closed or not in use',
message:'Please allow your background Geo permission to get the offer notification if you go near the store.',
positiveAction: 'Change to Allow all the time',
negativeAction: 'Cancel'
}
Expected Behavior
Location tracking should work after the app terminates.
Actual Behavior
Location tracking is not working after the app terminates, but it's working fine if the app opens or minimizes.
Steps to Reproduce
Context
Debug logs
Logs
PASTE_YOUR_LOGS_HERE
debug: false, // <-- enable this hear sounds for background-geolocation life-cycle.
When having a problem, set debug: true
so you can hear debug SoundFX. Also see wiki "Debugging" and learn to fetch logs from the plugin using .emailLog
or stream the logs in real time using $ adb logcat *:S TSLocationManager:V
.
@christocracy Thank you very much for your reply. Could you please check the log file and tell me why it is not working? background-geolocation.log Thank you.
This issue is stale because it has been open for 30 days with no activity.
This issue was closed because it has been inactive for 14 days since being marked as stale.