Skip to content
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

Custom error types #669

Open
Djuffin opened this issue Apr 27, 2023 · 5 comments
Open

Custom error types #669

Djuffin opened this issue Apr 27, 2023 · 5 comments

Comments

@Djuffin
Copy link
Contributor

Djuffin commented Apr 27, 2023

Currently WebCodecs rely on DOMExceptions with different names, but DOMException names are deprecated .
For proper and granular error reporting WebCodecs might need a special error type, like WebGpu pipeline error.

We might also need a special error type for rejecting promises and reporting errors via VideoEncoder and VideoDecoder callbacks.

@chrisn
Copy link
Member

chrisn commented May 11, 2023

Looking at the list of DOMException names it's only IndexSizeError, InvalidAccessError, TypeMismatchError, and URLMismatchError that are marked as deprecated. The WebCodecs spec doesn't use any of those so I think we're OK in that regard.

@Djuffin Djuffin self-assigned this May 11, 2023
@aboba
Copy link
Collaborator

aboba commented May 30, 2023

Can we use EncodingError to indicate an issue with the data provided to the Encoder/Decoder, and something else (e.g. OperationError) to indicate a resource issue (e.g. hardware encoder resource no longer available),

@xingri
Copy link

xingri commented May 30, 2023

@Djuffin, @aboba If it is possible, can I get a reference on the current working in progress?
Would like to investigate any possible changes on application side.

@chrisn
Copy link
Member

chrisn commented May 30, 2023

Discussed in Media WG meeting, 30 May 2023, minutes.

@xingri
Copy link

xingri commented May 30, 2023

Discussed in Media WG meeting, 30 May 2023, minutes.

Thanks @chrisn for the update.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants