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

reportError(), undefined, and ErrorEvent #7853

Closed
annevk opened this issue Apr 25, 2022 · 0 comments · Fixed by #7983
Closed

reportError(), undefined, and ErrorEvent #7853

annevk opened this issue Apr 25, 2022 · 0 comments · Fixed by #7983
Labels
interop Implementations are not interoperable with each other topic: error reporting topic: events

Comments

@annevk
Copy link
Member

annevk commented Apr 25, 2022

reportError(undefined) constructs an ErrorEvent instance whose error member will return undefined, but you cannot emulate this in userland (as ErrorEventInit's error dictionary member defaults to null).

Based on discussion in web-platform-tests/wpt#33206 we have two options:

  1. Remove ErrorEventInit's error's default.
  2. Map undefined to null.
  3. Keep the specification as-is. Only reportError() gets to construct these kind of ErrorEvent instances.

cc @evilpie @domenic @mfreed7 @nayeemrmn

@annevk annevk added topic: events interop Implementations are not interoperable with each other agenda+ To be discussed at a triage meeting labels Apr 25, 2022
@past past removed the agenda+ To be discussed at a triage meeting label Jun 2, 2022
annevk added a commit that referenced this issue Jun 3, 2022
This ensures that ErrorEvent has equivalent expressiveness to reportError().

Fixes #7853.
annevk added a commit that referenced this issue Jun 7, 2022
This ensures that ErrorEvent has equivalent expressiveness to reportError().

Fixes #7853.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
interop Implementations are not interoperable with each other topic: error reporting topic: events
Development

Successfully merging a pull request may close this issue.

3 participants