question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

getLocations doesn't return all locations in 3.0.0-alpha.48

See original GitHub issue

Your Environment

  • Plugin version: 3.0.0-alpha.48
  • Platform: Android
  • OS version: 8.0.0 / 7.0.0
  • Device manufacturer and model: S8 / Redmi Note4
  • Cordova version (cordova -v): 8.1.2
  • Cordova platform version (cordova platform ls): android 7.1.0 ios 4.5.5
  • Plugin configuration options:
{
       locationProvider: BackgroundGeolocation.ACTIVITY_PROVIDER,
       desiredAccuracy: BackgroundGeolocation.HIGH_ACCURACY,
       stationaryRadius: distance,
       distanceFilter: distance,
       notificationTitle: "Locator is tracking",
       notificationText: "Locator is enabled",
       debug: false,
       interval: 10000,
       fastestInterval: 5000,
       activitiesInterval: 10000,
       stopOnTerminate: true,
       startOnBoot: false,
       startForeground: true,
       maxLocations: 100000
}
  • Link to your project:

Context

I am invoking BackgroundGeolocation.getLocations to get all stored locations or at least the last 100k.

Expected Behavior

I was expecting to receive all locations stored (or at least the last 100k), instead, I have just few, but certainly not all. I compared alpha.48 to alpha.47 where all is working just fine and I can retrieve all locations stored for the certain period.

Actual Behavior

I have received few locations but they are not all. To compare - I have the app compiled with 47. In this case I have received approx 60 locations for ~10 mins. In 48, for the same timespan and going through the same route, I have received just 6 locations. Please note, I kept all other options the same, only plugin changed.

BTW - I noticed one visual difference - until 47 version, the plugin created dummy account into device’s account place. Since 48, the account now is named after the app.

Possible Fix

Steps to Reproduce

  1. Compile with 47 and make some movements (I walked around approx 10 mins)
  2. Invoke BackgroundGeolocation.getLocations and see how many locations have been returned from the plugin
  3. Compile with 48 and follow the same route and time duration
  4. Invoke BackgroundGeolocation.getLocations and check the number of returned locations. In my case they were 10 times less.

Context

Debug logs

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:18 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
mauron85commented, Dec 6, 2018

Will do some more tests with two of my Android devices.

1reaction
mauron85commented, Dec 3, 2018

I can see 2 locations already created

yes, I can confirm that. Will take look at it

until 47, the plugin creates account named dummy into device accounts

this is not relevant in this context

Read more comments on GitHub >

github_iconTop Results From Across the Web

cordova-plugin-mauron85-background-geolocation - UNPKG
54, Since alpha.47: 55, - allow nested location props in postTemplate. 56. 57, #### Changed. 58, - start and stop methods doesn't accept...
Read more >
stopOnTerminate = false does not behave as expected #490
The location event is not fired, hence, the app cannot track the location, after it is being terminated. Possible Fix. Steps to Reproduce....
Read more >
npm fails to install - Google Groups
48 verbose lock /Users/jmiele/.npm/appium/0.7.1/package.tgz ... logs to be stored in a persistent remote location (like a database), but all logs output to ...
Read more >
Spring Boot Reference Documentation
All of Spring Boot is open source, including the documentation. If you find problems with the docs or if you want to improve...
Read more >
Match property for profile activation against a regex - Apache
Not only is that setup fragile against job name changes, but also doesn't scale ... -Run Ant, specifying a location into which the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found