Git Product home page Git Product logo

Comments (4)

chaicai333 avatar chaicai333 commented on June 17, 2024 3

i have the same problem

from flutter-permission-plugins.

KingWu avatar KingWu commented on June 17, 2024

Have the same issue

from flutter-permission-plugins.

mvanbeusekom avatar mvanbeusekom commented on June 17, 2024

@mockturtl this is expected behaviour and only occurs when your "Info.plist" doesn't include the correct permissions.

In this case you are actively requesting "locationAlways" permissions while the permissions in your "Info.plist" only contain the NSLocationWhenInUseUsageDescription key.

You have two solutions here:

  1. Don't request "locationAlways" permissions (e.g. switch to "locationWhenInUse");
  2. Or add the missing permissions to your "Info.plist";

Hope this helped solve your issue.

from flutter-permission-plugins.

mockturtl avatar mockturtl commented on June 17, 2024

@mvanbeusekom Thank you for the reply and the workaround. I did discover both your suggestions through trial and error, and they solved it, but it was a little frustrating.

In this case you are actively requesting "locationAlways" permissions

That's confusing, to me. I call the API with the default value for the optional parameter, LocationPermissionLevel.location. To me, that means I am actively not requesting a different value.

enum LocationPermissionLevel {
  location,  // is this Android only?  What does it mean in Android 10?
  locationWhenInUse,
  locationAlways,
}

Please reconsider documenting this behavior, or the intended usage -- judging by the upvotes, it could be a little more clear.

@athornz

from flutter-permission-plugins.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.