Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDK48: background location updates frequency with taskmanager #28327

Open
vincentgTroopers opened this issue Apr 19, 2024 · 0 comments
Open

SDK48: background location updates frequency with taskmanager #28327

vincentgTroopers opened this issue Apr 19, 2024 · 0 comments
Labels
Location needs review Issue is ready to be reviewed by a maintainer TaskManager

Comments

@vincentgTroopers
Copy link

vincentgTroopers commented Apr 19, 2024

Minimal reproducible example

https://github.com/vincentgrassin/expo-sdk48-taskmanager

What platform(s) does this occur on?

Android

Did you reproduce this issue in a development build?

Yes

Summary

Using expo sdk 48 and task manager the background location updates occur with an unexpected frequency.
The location updates are working well when the app is on foreground (log every 1second) but when the app is on background the updates are less frequents (log every 10min - 20min).

Doing the exact same thing with expo sdk50 I can observe that the updates are working well both foreground and background (log every 1 seconds).

Current package.json: "expo": "48.0.0", "react": "18.2.0", "react-native": "0.71.14", "expo-task-manager": "~11.1.1", "expo-location": "~15.1.1"
The implementation seems the one given in basic Taskmanager documentation https://docs.expo.dev/versions/v48.0.0/sdk/task-manager/

As I am not able to upgrade to sdk 50 yet, Is it a known issue with startLocationUpdatesAsync ? is there a workaround ? Or maybe I am doing something wrong ?

Thanks in advance

Environment

expo-env-info 1.2.0 environment info:
System:
OS: Linux 6.5 Ubuntu 22.04.3 LTS 22.04.3 LTS (Jammy Jellyfish)
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 16.15.0 - ~/.nvm/versions/node/v16.15.0/bin/node
Yarn: 1.22.21 - ~/Documents/dev/sandbox/node_modules/.bin/yarn
npm: 8.5.5 - ~/.nvm/versions/node/v16.15.0/bin/npm
npmPackages:
expo: 48.0.0 => 48.0.0
react: 18.2.0 => 18.2.0
react-native: 0.71.14 => 0.71.14
npmGlobalPackages:
eas-cli: 3.8.0
expo-cli: 6.3.10
Expo Workflow: managed

Expo Doctor Diagnostics

✔ Check Expo config for common issues
✔ Check package.json for common issues
✔ Check native tooling versions
✔ Check dependencies for packages that should not be installed directly
✔ Check for common project setup issues
✔ Check for issues with metro config
✔ Check npm/ yarn versions
✔ Check Expo config (app.json/ app.config.js) schema
✔ Check that packages match versions required by installed Expo SDK
✔ Check that native modules do not use incompatible support packages
✔ Check for legacy global CLI installed locally
✔ Check that native modules use compatible support package versions for installed Expo SDK

Didn't find any issues with the project!

@vincentgTroopers vincentgTroopers added the needs validation Issue needs to be validated label Apr 19, 2024
@expo-bot expo-bot added needs review Issue is ready to be reviewed by a maintainer and removed needs validation Issue needs to be validated labels Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Location needs review Issue is ready to be reviewed by a maintainer TaskManager
Projects
None yet
Development

No branches or pull requests

3 participants