New issue
Advanced search Search tips

Issue 732038 link

Starred by 5 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 3
Type: Feature

Blocked on:
issue 837406


Show other hotlists

Hotlists containing this issue:
Hotlist-1
Hotlist-1


Sign in to add a comment

Support WebUSB in Dedicated, Shared and Service Worker contexts

Reported by aa...@xqz.ca, Jun 10 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.86 Safari/537.36

Steps to reproduce the problem:
1. Nurture a desire to put USB interaction on a separate thread
2. Become disappointed that it's beyond your reach

What is the expected behavior?
WebUSB has a lot of potential, probably a lot more than people are creative enough to think of right now. I am trying to port SANE (scanner drivers) to WebUSB. 

I thought it was natural to put the USB code on a Worker or SharedWorker, because USB devices (and particularly scanners) are timing-sensitive. If I leave the device in an undefined state, or wait too long to process something, it could eventually cause damage or excessive wear to the device.

I think that being off the main event loop is probably important for most non-trivial USB devices, so I would like to be able to access WebUSB from a Worker, and preferably from the other types of worker as well (within the limits of SOP and all that lovely jazz).

What went wrong?
I'm not emotionally prepared for this question.

Did this work before? No 

Chrome version: 61.0.3126.0  Channel: canary
OS Version: OS X 10.12.5
Flash Version: 

WebUSB is awesome, I hope it can firm up over the next year so that the latency testers, hardware diagnostic tools, sporadic-use drivers, drivers for ChromeOS, and device configurators can some day all function reasonably reliably within a browser.
 
Cc: kkaluri@chromium.org
Components: Blink>USB
Labels: M-61
Status: Untriaged (was: Unconfirmed)
aaron@ Thank You for filling in, this is a feature request, marking it as untriaged for further triage from dev team.

Thank You....
Cc: reillyg@chromium.org
Labels: -Pri-2 -M-61 OS-Android OS-Chrome OS-Linux OS-Windows Pri-3
Status: Available (was: Untriaged)
There is an open spec issue for this: https://github.com/WICG/webusb/issues/73

Removing milestone because this probably isn't happening for M-61.
Blockedon: 837406
Summary: Support WebUSB in Dedicated, Shared and Service Worker contexts (was: WebUSB should be available from a Worker)
Updating the title of this issue to reflect the variety of worker contexts WebUSB could be made available in.  Issue 837406  covers dedicated workers and that is shipping in M-70. Other worker types are still being investigated.

Shared workers are complex due to questions of how to track WebUSB usage across multiple frames (mostly Chrome internal complexity) while services workers are complex because this could permit access to WebUSB in the background which raises permissions and privacy considerations.

Sign in to add a comment