- From: Domenic Denicola via GitHub <sysbot+gh@w3.org>
- Date: Thu, 25 Feb 2021 21:02:37 +0000
- To: public-device-apis-log@w3.org
Oh, it looks like [Blink doesn't implement the spec's secure context restriction at all](https://source.chromium.org/chromium/chromium/src/+/master:third_party/blink/renderer/modules/battery/battery_manager.cc;l=29-30;drc=6531b4f2fda5515c3315e50d1cfb709e607d53e6), wow. So there are three possible behaviors: 1. The current implementation: works fine in a non-secure context 2. The current spec: returns a rejected promise in a non-secure context 3. The ideal spec: throws an exception (because the method doesn't exist at all because it's guarded with `[SecureContext]`) in a non-secure context That's... tricky. I guess my preference would be to remove the secure context restriction from the spec entirely, add a warning box pointing to this issue, and then as a separate effort, try to move the spec and implementation toward (3), if we think it's worth the engineering effort? -- GitHub Notification of comment by domenic Please view or discuss this issue at https://github.com/w3c/battery/issues/15#issuecomment-786200725 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 25 February 2021 21:02:39 UTC