radarlabs / react-native-radar

React Native module for Radar, the leading geofencing and location tracking platform
https://radar.com
Apache License 2.0
170 stars 32 forks source link

Tracking gets "stale" when app is updated #324

Open ChromeQ opened 5 months ago

ChromeQ commented 5 months ago

Summary

I have an Expo React Native app with Radar SDK integrated. It allows users to grant always on background location, and tracking is started using startTrackingResponsive(). This works as expected and I see events and activity in the Radar dashboard.

Now I have a new version of the app to publish, and my testing has found that once the app in updated it no longer tracks a user, despite the isTracking() method returning true.

Steps to reproduce

My testing was done like this: Build and install the app (version 9) App will initialize Radar on start Turn on background location Walk around a bit Verify user is tracked on https://radar.com/dashboard/geofencing/users

Make a small UI change to the app (just to confirm the new version) Build the app (version 10) and upgrade (rather than uninstall and re-install) Open the app and confirm the new version and isTracking is true Walk around a bit Check if user is still tracked - it is not

SDK installation method

yarn

SDK version

3.12.1

Other information

I am only testing Android at the moment as it is easy to build and install APK files, when tapping the updated version of the app it asks if I want to update the app, which I am hoping is the same as doing it via Play Store (?) I have also been setting some metadata immediately after initialize and that is also failing to get updated in the Radar website. The "Updated at" is not updating.

If I uninstall and reinstall the new version of the app (then turn on permissions etc) then all data comes through as expected.

I know this is a bit difficult and awkward to test, I have tried using the simulator but of course that works, the updates need to come from the device and it seems that they are not being sent to Radar once the app is updated.

ChromeQ commented 5 months ago

Small update: I have also tested this on iOS and it does seem to track fine after the update. The "Updated at" and metadata both updated even without opening the app after updating (Updated via Safari using QR code and not Test Flight, but I am sure it will work that way too)

vanlueckn commented 2 months ago

I have the same issue. I need to uninstall and install the android apk after each update.