-
-
Notifications
You must be signed in to change notification settings - Fork 727
Open
Labels
P2Important issues not at the top of the work list.Important issues not at the top of the work list.background-foreground-locationplatform: androidIssue is related to the Android platform.Issue is related to the Android platform.type: bugSomething isn't workingSomething isn't working
Description
Please check the following before submitting a new issue.
- I have searched the existing issues.
- I have carefully read the documentation and verified I have added the required platform specific configuration.
Please select affected platform(s)
- Android
- iOS
- Linux
- macOS
- Web
- Windows
Steps to reproduce
trigger every 15s the method: getCurrentPosition() or listen on the location stream.
after some time (1-2h) we don't receive position updates when the phone is locked. We receive timeouts. what can i do?
when i unlocked the phone, then i receive all positions imediately. My Service is running in a foreground service.
Expected results
actual GPS position
Actual results
timeout errors
Code sample
Code sample
Position? position = await GeolocatorPlatform.instance
.getCurrentPosition(locationSettings: const LocationSettings(accuracy: LocationAccuracy.bestForNavigation, timeLimit: Duration(seconds: 30)));
Screenshots or video
Screenshots or video demonstration
[Upload media here]
Version
9.0.2
Flutter Doctor output
Doctor output
[√] Flutter (Channel stable, 3.10.5, on Microsoft Windows [Version 10.0.19044.3086], locale en-CH)
• Flutter version 3.10.5 on channel stable at C:\Flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 796c8ef792 (7 weeks ago), 2023-06-13 15:51:02 -0700
• Engine revision 45f6e00911
• Dart version 3.0.5
• DevTools version 2.23.1
[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
• Android SDK at C:\Users\Roy\AppData\Local\Android\Sdk
• Platform android-33, build-tools 30.0.3
• ANDROID_HOME = C:\Users\Roy\AppData\Local\Android\Sdk
• Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java
• Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-9586694)
• All Android licenses accepted.
[√] Chrome - develop for the web
• Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe
[√] Visual Studio - develop for Windows (Visual Studio Professional 2019 16.11.2)
• Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional
• Visual Studio Professional 2019 version 16.11.31624.102
• Windows 10 SDK version 10.0.20348.0
[√] Android Studio (version 2022.2)
• Android Studio at C:\Program Files\Android\Android Studio
• 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.6+0-b2043.56-9586694)
[√] VS Code, 64-bit edition (version 1.78.2)
• VS Code at C:\Program Files\Microsoft VS Code
• Flutter extension version 3.68.0
[√] Connected device (4 available)
• SM A715F (mobile) • R58R13LKH1P • android-arm64 • Android 13 (API 33)
• Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version 10.0.19044.3086]
• Chrome (web) • chrome • web-javascript • Google Chrome 115.0.5790.110
• Edge (web) • edge • web-javascript • Microsoft Edge 114.0.1823.79
[√] Network resources
• All expected network resources are available.
• No issues found!
ignaciograsso, HeropolisDa2ny and ZTMIDGO
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work list.Important issues not at the top of the work list.background-foreground-locationplatform: androidIssue is related to the Android platform.Issue is related to the Android platform.type: bugSomething isn't workingSomething isn't working