Skip to content

Allow for async permission request when first accessing sensor data #20

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

Closed
1 task done
tobie opened this issue May 27, 2015 · 5 comments
Closed
1 task done

Allow for async permission request when first accessing sensor data #20

tobie opened this issue May 27, 2015 · 5 comments
Milestone

Comments

@tobie
Copy link
Member

tobie commented May 27, 2015

Make sure the API is compatible with sensors which need to ask the user's permission before being used.

Proposed resolutions:

  • The Generic Sensor API must be compatible with an async permissioning model.

Actions:

  • Identify the best solution to communicate that the permission to access the sensor has been denied by the user agent.
@tobie tobie added this to the FPWD milestone May 27, 2015
@rwaldron
Copy link
Contributor

The "value is null until first reading is delivered" should work really well with user permission prompting.

let geo = new Sensor.Geolocation(); // <-- this will trigger some kind of permission request to the user

geo.lat; // null until user grants permission, which might be never

geo.on("change", function() {
  // will only ever be invoked if the user grants permission, which might be never. 
});

@tobie tobie added the action label May 27, 2015
@tobie
Copy link
Member Author

tobie commented May 27, 2015

Yup. Might need to emit a PERMISSION_DENIED error event of some sort.

@tobie tobie removed the action label May 28, 2015
@marcoscaceres
Copy link
Member

I'm watching this repo, but please ping me and I'll try to help in any way I can.

@tobie
Copy link
Member Author

tobie commented May 28, 2015

@marcoscaceres creating a dedicated issue for discussing the Permission API: #22.

@tobie tobie changed the title Permissioning Allow for async permission request when first accessing sensor data May 28, 2015
@tobie tobie modified the milestones: Level 1, FPWD Oct 16, 2015
@tobie
Copy link
Member Author

tobie commented Mar 22, 2016

Depends on ongoing work on the Permission API: w3c/permissions#66

@tobie tobie closed this as completed Mar 22, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants