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

[Bug]: The error is that the permission popup reappears when the screen is turned off on iOS. #1478

Open
3 of 8 tasks
bsv-khanhton opened this issue Apr 11, 2024 · 1 comment
Assignees
Labels
P2 Important issues not at the top of the work list. type: bug Something isn't working

Comments

@bsv-khanhton
Copy link

Please check the following before submitting a new issue.

Please select affected platform(s)

  • Android
  • iOS
  • Linux
  • macOS
  • Web
  • Windows

Steps to reproduce

  1. Open the application and request location permission.
  2. When the location permission popup appears, turn off the screen (without selecting any option on the popup).
  3. Press the home button to reopen. At this point, the operating system has closed the location permission popup. When calling the location permission request command again, the library returns an error "A request for location permissions is already running, please wait for it to complete before doing another request.".

Expected results

You can recall the permission request in this case

Actual results

Unable to recall the permission request in case the operating system closes the previous permission popup.

Code sample

Code sample
await  Geolocator.requestPermission();

Screenshots or video

Screenshots or video demonstration

Screenshot 2024-04-11 at 17 45 17

Version

10.4.2

Flutter Doctor output

Doctor output
[!] Flutter (Channel stable, 3.13.9, on macOS 14.2 23C64 darwin-x64, locale en-US)
    • Flutter version 3.13.9 on channel stable at /Users/bravesoft/Desktop/flutter/sdk/flutter
    ! Warning: `dart` on your path resolves to /usr/local/Cellar/dart/2.17.6/libexec/bin/dart, which is not inside your current Flutter SDK checkout at /Users/bravesoft/Desktop/flutter/sdk/flutter. Consider adding /Users/bravesoft/Desktop/flutter/sdk/flutter/bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision d211f42860 (6 months ago), 2023-10-25 13:42:25 -0700
    • Engine revision 0545f8705d
    • Dart version 3.1.5
    • DevTools version 2.25.0
    • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.

[!] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/bravesoft/Library/Android/sdk/
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/macos#android-setup for more details.

[✓] Xcode - develop for iOS and macOS (Xcode 15.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15C65
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.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 11.0.15+0-b2043.56-8887301)

[✓] VS Code (version 1.68.1)
    • VS Code at /Users/bravesoft/Downloads/Visual Studio Code.app/Contents
    • Flutter extension can be installed from:
      🔨 https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[✓] Connected device (3 available)
    • iPhone SE (3rd generation) (mobile) • 18CB3D56-33C9-4D4B-BD9C-629CC408E484 • ios            • com.apple.CoreSimulator.SimRuntime.iOS-17-2 (simulator)
    • macOS (desktop)                     • macos                                • darwin-x64     • macOS 14.2 23C64 darwin-x64
    • Chrome (web)                        • chrome                               • web-javascript • Google Chrome 123.0.6312.107
    ! Error: Browsing on the local area network for iPhoneKhanhTon. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.
@TimHoogstrate TimHoogstrate self-assigned this Apr 22, 2024
@TimHoogstrate
Copy link
Contributor

Dear @bsv-khanhton,

This is a known issue and we are working on a solution. That is because we don't know when a pop-up is dismissed by the OS. I'll label this as a bug but there are more duplicates in the list.

Kind regards,

@TimHoogstrate TimHoogstrate added type: bug Something isn't working P2 Important issues not at the top of the work list. labels Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2 Important issues not at the top of the work list. type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants