mauron85 / react-native-background-geolocation

Background and foreground geolocation plugin for React Native. Tracks user when app is running in background.
Apache License 2.0
1.34k stars 565 forks source link

Android 10 support #525

Open farruxx opened 3 years ago

farruxx commented 3 years ago

Your Environment

Android 10 introduces new background geolocation runtime permission ACCESS_BACKGROUND_LOCATION Please add support this permission. Without it, there is no option "Allow all the time"

Context

Expected Behavior

Actual Behavior

Possible Fix

Steps to Reproduce

1. 2. 3. 4.

Context

Debug logs

maxconnectAbhi commented 3 years ago

need this

darron1217 commented 3 years ago

I created fork to solve this issue. (And it also fixes Gradle4 issue) https://github.com/darron1217/react-native-background-geolocation

(Edit) You can install it by command below

yarn add @darron1217/react-native-background-geolocation
Adigezalov commented 3 years ago

@darron1217 Hello I installed your fork. But in it during installation the node_modules/@mauron85/react-native-background-geolocation/android/common folder is empty

darron1217 commented 3 years ago

@Adigezalov Did you try re-installing the package? (npm remove and npm install)

Adigezalov commented 3 years ago

@darron1217 Yes of course. Repeatedly.

darron1217 commented 3 years ago

@Adigezalov What's your npm or yarn version?

(Edit) yarn seems not supporting submodule. https://github.com/yarnpkg/yarn/issues/1488

mwsoofy commented 3 years ago

Hey guys, Any of you face the background location sending stops in lock screen on android 10 ?

Adigezalov commented 3 years ago

@darron1217 This was indeed a problem in yarn. Thank you for your help

Adigezalov commented 3 years ago

@darron1217 But my coordinates are not updated in the case of a killed application

darron1217 commented 3 years ago

@Adigezalov Did you select "Allow all" on dialog?

If then, submit an issue here https://github.com/darron1217/react-native-background-geolocation/issues

Adigezalov commented 3 years ago

@darron1217 yes I select "Allow all" on dialog Open issue https://github.com/darron1217/react-native-background-geolocation/issues/1

guilhermeadsferreira commented 3 years ago

Why it not working with yarn ? I had to use npm

darron1217 commented 3 years ago

@Adigezalov @guilhermeadsferreira I've uploaded it on npm. Now you can install it by yarn add @darron1217/react-native-background-geolocation (I changed package name, so you might need to change it on your code)

SujashJoshi commented 3 years ago

@darron1217 I'm comparatively new on this, I've included mauron's package, can I directly import yours too on this?