Intent to Ship: AudioContext.onerror

37 views
Skip to first unread message

Ajay Rahatekar

unread,
Jul 11, 2024, 1:06:53 AM (5 days ago) Jul 11
to blink-dev, hongchan, mjwi...@chromium.org

Contact emails

hong...@chromium.org, mjwi...@chromium.org


Explainer

None; the specification (W3C Proposed Recommendation) is already published.


Specification

https://webaudio.github.io/web-audio-api/#dom-audiocontext-onerror

Summary

Introduces an event listener on AudioContext to notify developers of audio device or rendering system failures.


Blink component

Blink>WebAudio


Motivation

Currently, developers lack visibility into the success or failure of their AudioContext, whether during its creation or while actively rendering audio. In the event of failure, web applications misleadingly continue to function as if audio playback is proceeding normally. The AudioContext.onerror event listener allows web applications to proactively respond to and manage device or rendering failures.


Initial public proposal

https://github.com/WebAudio/web-audio-api/issues/2567


TAG review

http://github.com/w3ctag/design-reviews/issues/950 


TAG review status

Resolved


Risks


Interoperability and Compatibility


Gecko: Positive  (http://github.com/mozilla/standards-positions/issues/1016)


WebKit: Defer to Audio WG (https://github.com/WebKit/standards-positions/issues/340)


Web developers: Positive (2020 Developer Survey)


WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?

None


Debuggability

None


Is this feature fully tested by web-platform-tests?

No, AudioContext failure scenarios cannot be tested in WPTs. Chromium-internal tests will fully exercise this scenario.


Flag name on chrome://flags

None


Finch feature name

AudioContextOnError


Non-finch justification

N/A


Requires code in //chrome?

False


Tracking bug

https://crbug.com/41495720


Launch bug

https://launch.corp.google.com/launch/4317143


Estimated milestones

M128


Note

The team has requested Privacy and Security approval on the chromestatus entry. The same gates have already been approved on the internal launch bug.


Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5113439453446144


This intent message was generated by Chrome Platform Status.


Domenic Denicola

unread,
Jul 11, 2024, 2:22:11 AM (5 days ago) Jul 11
to blink-dev, ajayra...@google.com, hongchan, mjwi...@chromium.org
I've filed a spec issue that I believe should be addressed before shipping (with appropriate test updates, etc.) https://github.com/WebAudio/web-audio-api/issues/2590

Hongchan Choi

unread,
10:22 AM (10 hours ago) 10:22 AM
to Domenic Denicola, blink-dev, ajayra...@google.com
Hi Domenic,

Thanks for your input! I've addressed the issue you opened with 2 PRs:

Regarding the test updates, what would you like to see other than basic IDL tests? This event can be dispatched only with device failure, which is impossible to emulate on WPT.

Or do we want a more involved "device mocking" for testing?

Best,
Hongchan

Reply all
Reply to author
Forward
0 new messages