forceSync() method not working on iOS
forceSync() method not working on iOS
I am trying to create a solution where the received locations are shared with the API only after N locations, using syncUrl parameter. Except, when the user decides to stop sharing his location (by pressing a stop button) I want to force the synchronization of the locations that haven't been shared yet.
On iOS, the onSuccess of syncUrl() is not called. Same thing for getValidLocations().
Working on Android.
Your Environment
- Plugin version: 0.6.3
- Platform: iOS
- OS version: 13.3.1
- Device manufacturer and model: iPhone XR and iPhone 11
- Running in Simulator: Both
- React Native version: 0.62
System: OS: macOS 10.15.3 CPU: (4) x64 Intel(R) Core(TM) i5-5257U CPU @ 2.70GHz Memory: 132.63 MB / 8.00 GB Shell: 5.7.1 - /bin/zsh Binaries: Node: 13.12.0 - /usr/local/bin/node Yarn: 1.22.0 - /usr/local/bin/yarn npm: 6.14.4 - /usr/local/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman SDKs: iOS SDK: Platforms: iOS 13.4, DriverKit 19.0, macOS 10.15, tvOS 13.4, watchOS 6.2 Android SDK: API Levels: 23, 26, 27, 28, 29 Build Tools: 28.0.3 System Images: android-29 | Google Play Intel x86 Atom Android NDK: 19.0.5232133 IDEs: Android Studio: 3.6 AI-192.7142.36.36.6200805 Xcode: 11.4/11E146 - /usr/bin/xcodebuild npmPackages: @react-native-community/cli: ^4.5.1 => 4.6.3 react: 16.11.0 => 16.11.0 react-native: 0.62.0 => 0.62.0 npmGlobalPackages: react-native-cli: 2.0.1
Context
I receive onSuccess on android but not on iOS
Expected Behavior
Receive onSuccess on iOS
Actual Behavior
Possible Fix
Steps to Reproduce
Context
Well, I'm using url and not syncUrl on iOS because of this
Debug logs
Probably not related but on android, I get strange results when testing the app with syncUrl mode enabled:
I get like a lot of locations and they are kind of unordered, as you can see on my screenshot :
I was going from east to west, but according to the locations I kept going back and forth, and the total distance on the API was around 13km instead of around 2km
Maybe by @time not recorded?
Seem like @mauron85 no longer maintain this project. Do you want to bring it to react-native-community?
If this lib bring to react-native-community it will be best.