Skip to content

Remove ErrorEventInit's error default - #7983

Merged
annevk merged 1 commit into
mainfrom
annevk/erroreventinit
Jun 7, 2022
Merged

annevk merged 1 commit into
mainfrom
annevk/erroreventinit

Conversation

@annevk

@annevk annevk commented Jun 3, 2022 •

Copy link
Copy Markdown
Member

This ensures that ErrorEvent has equivalent expressiveness to reportError().

Fixes #7853.


See whatwg/webidl#983 for why this removes the default and does not change it to be undefined.

As discussed during #7919.


(See WHATWG Working Mode: Changes for more details.)


/webappapis.html ( diff )

This ensures that ErrorEvent has equivalent expressiveness to reportError().

Fixes #7853.
@annevk annevk added normative change topic: events Event handlers, their content and IDL attributes, and the events HTML fires labels Jun 3, 2022
annevk added a commit to web-platform-tests/wpt that referenced this pull request Jun 3, 2022
This accounts for the change in whatwg/html#7983 as well.
@smaug----

Copy link
Copy Markdown

Comment thread source
unsigned long lineno = 0;
unsigned long colno = 0;
any error = null;
any error;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we're happy enough with the progress on whatwg/webidl#983 I can change this to = undefined instead and remove the prose change below.

@domenic domenic left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM either way.

@annevk
annevk force-pushed the annevk/erroreventinit branch from 21450b2 to dd8bbaf Compare June 7, 2022 06:58
annevk added a commit to web-platform-tests/wpt that referenced this pull request Jun 7, 2022
This accounts for the change in whatwg/html#7983 as well.
@annevk
annevk merged commit 0325231 into main Jun 7, 2022
@annevk
annevk deleted the annevk/erroreventinit branch June 7, 2022 07:06
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Jun 10, 2022
…testonly

Automatic update from web-platform-tests
HTML: assert ErrorEventInit defaults

This accounts for the change in whatwg/html#7983 as well.
--

wpt-commits: c297f88500de105a82118d1a5527d52e63c7ba47
wpt-pr: 34297
webkit-early-warning-system pushed a commit to cdumez/WebKit that referenced this pull request Jun 23, 2022
https://bugs.webkit.org/show_bug.cgi?id=241259
<rdar://94793559>

Reviewed by Darin Adler.

Update ErrorEventInit's error default to be undefined instead of null, as per:
- whatwg/html#7983

* LayoutTests/imported/w3c/web-platform-tests/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html:
* Source/WebCore/dom/ErrorEvent.cpp:
(WebCore::ErrorEvent::error):
* Source/WebCore/dom/ErrorEvent.idl:

Canonical link: https://commits.webkit.org/251797@main
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Jul 7, 2022
Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
aarongable pushed a commit to chromium/chromium that referenced this pull request Jul 7, 2022
Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3749784
Reviewed-by: Joey Arhar <[email protected]>
Commit-Queue: Joey Arhar <[email protected]>
Auto-Submit: Mason Freed <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1021841}
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Jul 7, 2022
Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3749784
Reviewed-by: Joey Arhar <[email protected]>
Commit-Queue: Joey Arhar <[email protected]>
Auto-Submit: Mason Freed <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1021841}
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Jul 7, 2022
Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3749784
Reviewed-by: Joey Arhar <[email protected]>
Commit-Queue: Joey Arhar <[email protected]>
Auto-Submit: Mason Freed <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1021841}
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Jul 14, 2022
…ault value, a=testonly

Automatic update from web-platform-tests
Remove ErrorEventInit's error's null default value

Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3749784
Reviewed-by: Joey Arhar <[email protected]>
Commit-Queue: Joey Arhar <[email protected]>
Auto-Submit: Mason Freed <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1021841}

--

wpt-commits: 824d27822a6c110981a6bbb99dddbcdf8455f56a
wpt-pr: 34741
aosmond pushed a commit to aosmond/gecko that referenced this pull request Jul 15, 2022
…ault value, a=testonly

Automatic update from web-platform-tests
Remove ErrorEventInit's error's null default value

Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3749784
Reviewed-by: Joey Arhar <[email protected]>
Commit-Queue: Joey Arhar <[email protected]>
Auto-Submit: Mason Freed <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1021841}

--

wpt-commits: 824d27822a6c110981a6bbb99dddbcdf8455f56a
wpt-pr: 34741
@domenic domenic added the topic: error reporting Reporting script errors: the error event, onerror and reportError() label Jul 25, 2024
jwidar pushed a commit to jwidar/LatencyZeroGithub that referenced this pull request Sep 16, 2025
…testonly

Automatic update from web-platform-tests
HTML: assert ErrorEventInit defaults

This accounts for the change in whatwg/html#7983 as well.
--

wpt-commits: c297f88500de105a82118d1a5527d52e63c7ba47
wpt-pr: 34297
jwidar pushed a commit to jwidar/LatencyZeroGithub that referenced this pull request Sep 16, 2025
…ault value, a=testonly

Automatic update from web-platform-tests
Remove ErrorEventInit's error's null default value

Per the spec change [1], this removes ErrorEventInit's default value
of null, which makes the error attribute have no null default.

This change has already shipped on WebKit and Gecko, and the change
makes Chromium match the spec and other implementations. This is tested
by this WPT:

wpt/html/webappapis/scripting/events/event-handler-processing-algorithm-error/document-synthetic-errorevent.html

[1] whatwg/html#7983

Fixed: 1332448
Change-Id: Ia64a62e8c5739ab278016a94b0c3b0419d6a68f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3749784
Reviewed-by: Joey Arhar <[email protected]>
Commit-Queue: Joey Arhar <[email protected]>
Auto-Submit: Mason Freed <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1021841}

--

wpt-commits: 824d27822a6c110981a6bbb99dddbcdf8455f56a
wpt-pr: 34741
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

normative change topic: error reporting Reporting script errors: the error event, onerror and reportError() topic: events Event handlers, their content and IDL attributes, and the events HTML fires

Development

Successfully merging this pull request may close these issues.

reportError(), undefined, and ErrorEvent

3 participants