Closed vanelizarov closed 10 months ago
Dear @vanelizarov,
I tried running your example on a GMS-less emulator but I am unable to reproduce this issue? Do you have the same issue when you run the example app?
Kind regards,
@TimHoogstrate
Yes, it's reproducible on AOSP-based API 31 (Android 12) image. You can run example from geolocator_android
replacing AndroidSettings
instance on line 285 with one I provided above and then click on red "play" button
Dear @vanelizarov,
However, the fix in your PR seems fine. I am still not able to reproduce the issue with the applied settings. But I am running a different AS version and emulator (although I don't think this will make a difference). I'll keep this issue open for so that the team can join me in the investigation. Linked PR
Hi @vanelizarov,
Thank you for reporting the issue and creating a PR with the solution. We have just merged your PR and published version 4.4.1 to pub.dev which should resolve this issue.
Hi @vanelizarov,
Thank you for reporting the issue and creating a PR with the solution. We have just merged your PR and published version 4.4.1 to pub.dev which should resolve this issue.
Cool!
Please check the following before submitting a new issue.
Please select affected platform(s)
Steps to reproduce
Run any example with getPositonStream on AOSP Android emulator
Expected results
No exception
Actual results
getPositionStream
causes anjava.lang.IllegalStateException: passive location requests must have an explicit minimum update interval
The problem is thatminUpdateIntervalMillis
property in location request is implicitly set to -1 by defaultCode sample
Code sample
```dart Geolocator.getPositionStream( locationSettings: AndroidSettings( accuracy: LocationAccuracy.lowest, timeLimit: const Duration(minutes: 1), ), ).listen((pos) => debugPrint('${pos}')) ```Screenshots or video
Screenshots or video demonstration
[Upload media here]Version
10.1.0
Flutter Doctor output
Doctor output
```console [✓] Flutter (Channel stable, 3.16.5, on macOS 14.2 23C64 darwin-arm64, locale en-US) • Flutter version 3.16.5 on channel stable at /Users/vanelizarov/flutter • Upstream repository https://github.com/flutter/flutter.git • Framework revision 78666c8dc5 (12 days ago), 2023-12-19 16:14:14 -0800 • Engine revision 3f3e560236 • Dart version 3.2.3 • DevTools version 2.28.4 [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0) • Android SDK at /Users/vanelizarov/Library/Android/sdk • Platform android-34, build-tools 34.0.0 • ANDROID_HOME = /Users/vanelizarov/Library/Android/sdk • ANDROID_SDK_ROOT = /Users/vanelizarov/Library/Android/sdk • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 17.0.7+0-17.0.7b1000.6-10550314) • All Android licenses accepted. [✓] Xcode - develop for iOS and macOS (Xcode 15.1) • Xcode at /Applications/Xcode.app/Contents/Developer • Build 15C65 • CocoaPods version 1.14.3 [✓] Chrome - develop for the web • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome [✓] Android Studio (version 2023.1) • Android Studio at /Applications/Android Studio.app/Contents • Flutter plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: 🔨 https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 17.0.7+0-17.0.7b1000.6-10550314) [✓] VS Code (version 1.85.1) • VS Code at /Applications/Visual Studio Code.app/Contents • Flutter extension version 3.80.0 [✓] Connected device (4 available) • Android SDK built for arm64 (mobile) • emulator-5554 • android-arm64 • Android 12 (API 31) (emulator) • macOS (desktop) • macos • darwin-arm64 • macOS 14.2 23C64 darwin-arm64 • Chrome (web) • chrome • web-javascript • Google Chrome 120.0.6099.129 [✓] Network resources • All expected network resources are available. • No issues found! ```