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
The application starts, there's a burst of activity from the library, onLocation registers updates, but there no http updates. After 3-6 location logs, the library goes completely silent and no records are logged or pushed to the endpoint. OnLocation, onMotionChange and onHttp record nothing. The only thing that works is the heartbeat. Another burst of location data is triggered if the user toggles the location on their device, then the library goes silent again. The results are the same, on the emulator with simulated route movement and on a physical device with actual movement.
Your Environment
Plugin version: 4.18.3
Platform: Android
OS version: 13
Device manufacturer / model: Samsung A515F
React Native version (react-native -v): 0.74.5
Plugin config
BackgroundGeolocation.ready({locationAuthorizationRequest: "Always",backgroundPermissionRationale: {title:
"Allow access to this device's location in the background?",message:
"This app accesses your location in order to assign and track shipment deliveries.",positiveAction: 'Change to "Allow all the time"',negativeAction: "Cancel",},desiredAccuracy: BackgroundGeolocation.DESIRED_ACCURACY_HIGH,debug: false,enableHeadless: true,logLevel: BackgroundGeolocation.LOG_LEVEL_VERBOSE,stopOnTerminate: false,startOnBoot: true,preventSuspend: true,disableStopDetection: true,pausesLocationUpdatesAutomatically: false,allowIdenticalLocations: false,showsBackgroundLocationIndicator: true,heartbeatInterval: 120,foregroundService: true,url: "https://myurl.com/locationsbatch",locationTemplate:
'{"lat":<%= latitude %>,"lng":<%= longitude %>,"speed":<%= speed %>,"timestamp":"<%= timestamp %>"}',autoSync: true,autoSyncThreshold: 10,batchSync: true,maxBatchSize: 20,headers: {"Content-Type": "application/json",Authorization: `Basic ${auth}`,},params: {driverID: userSub},maxDaysToPersist: 3,}).then(async(state)=>{BackgroundGeolocation.start(function(){console.log("- Start success");});console.log("- BackgroundGeolocation is configured and ready: ",state.enabled,);});
Expected Behavior
When location tracking starts, updates to the provided http url shuld continue until location tracking is stopped, even when the application is backgrounded.
Actual Behavior
When location tracking starts, there is only an initial burst of locations and a few http updates before the library goes dormant. The library repeats locations with the same timestamps when it starts logging sending http updates. Only toggling the location on the device triggers a burst of accurate logging before the library goes dormant again.
Steps to Reproduce
Run the application on an android device
Grant always permission
Turn on location
Observe
Context
I was trying to send batch location updates to my endpoint in the foreground and the background.
The application starts, there's a burst of activity from the library, onLocation registers updates, but there no http updates. After 3-6 location logs, the library goes completely silent and no records are logged or pushed to the endpoint. OnLocation, onMotionChange and onHttp record nothing. The only thing that works is the heartbeat. Another burst of location data is triggered if the user toggles the location on their device, then the library goes silent again. The results are the same, on the emulator with simulated route movement and on a physical device with actual movement.
Your Environment
react-native -v
): 0.74.5Expected Behavior
When location tracking starts, updates to the provided http url shuld continue until location tracking is stopped, even when the application is backgrounded.
Actual Behavior
When location tracking starts, there is only an initial burst of locations and a few http updates before the library goes dormant. The library repeats locations with the same timestamps when it starts logging sending http updates. Only toggling the location on the device triggers a burst of accurate logging before the library goes dormant again.
Steps to Reproduce
Context
I was trying to send batch location updates to my endpoint in the foreground and the background.
Debug logs
Logs
The text was updated successfully, but these errors were encountered: