compat-table icon indicating copy to clipboard operation
compat-table copied to clipboard

Test for unhandled promise rejection tracking

Open keirlawson opened this issue 9 years ago • 12 comments

As per https://github.com/tc39/ecma262/pull/76

keirlawson avatar Feb 16 '16 20:02 keirlawson

fwiw, that tracking is not part of the language spec. It's something browsers can choose to opt in to - and those hooks you linked to are just so that the browsers don't have to write overriding spec text.

I don't think it's something we should be testing for, because it's not required by ES - but nor is it something we can test for in any implementation I've seen (unhandled rejection tracking is console-only)

ljharb avatar Feb 16 '16 20:02 ljharb

I disagree. Promise rejection tracking events can be added as a part of a new table for ES-related HTML features, like #636.

zloirock avatar Feb 16 '16 21:02 zloirock

Sure, if it's in a new table that makes sense. The tests shouldn't be added until there's at least one browser implementation, though.

ljharb avatar Feb 16 '16 21:02 ljharb

It's implemented in Chrome 49+.

zloirock avatar Feb 16 '16 21:02 zloirock

Good to know - once that ships stable then my conditions are met :-)

ljharb avatar Feb 16 '16 21:02 ljharb

Strange condition. Why do you think so? :) It's a spec.

zloirock avatar Feb 16 '16 21:02 zloirock

Since Chrome supports this now, I'll see if I can add it to the table.

Daniel15 avatar May 15 '16 03:05 Daniel15

To which table? :) We still haven't a table for it.

zloirock avatar May 15 '16 03:05 zloirock

Haha. That's a good point. I guess it doesn't make sense on the ES6 page since it's specific to browsers. ¯_(ツ)_/¯

In any case, 'onunhandledrejection' in window seems to be a sufficient test for it. Looks like only Chrome supports it right now.

Daniel15 avatar May 15 '16 04:05 Daniel15

What about non-standard table?

kangax avatar May 15 '16 04:05 kangax

@kangax it's already a part of HTML standard. As I wrote before, makes sense add a new table for ES-related HTML features.

zloirock avatar May 15 '16 04:05 zloirock

IMO this should be on caniuse website instead. or we'll end up creating a copy of caniuse in a new tab of compat-table

chicoxyzzy avatar Oct 04 '16 20:10 chicoxyzzy