WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
223071
Implement AbortSignal.abort()
https://bugs.webkit.org/show_bug.cgi?id=223071
Summary
Implement AbortSignal.abort()
James M Snell
Reported
2021-03-11 08:14:24 PST
https://github.com/whatwg/dom/pull/960
introduces a new utility `AbortSignal.abort()` that creates and returns an already aborted AbortSignal. Example implementation in Node.js:
https://github.com/nodejs/node/pull/37693
. WPT Test:
https://github.com/web-platform-tests/wpt/pull/28003
Attachments
Patch
(6.62 KB, patch)
2021-03-19 13:59 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(10.35 KB, patch)
2021-03-22 08:32 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2021-03-18 09:15:15 PDT
<
rdar://problem/75575483
>
Chris Dumez
Comment 2
2021-03-19 13:59:21 PDT
Created
attachment 423772
[details]
Patch
EWS Watchlist
Comment 3
2021-03-19 14:00:35 PDT
This patch modifies the imported WPT tests. Please ensure that any changes on the tests (not coming from a WPT import) are exported to WPT. Please see
https://trac.webkit.org/wiki/WPTExportProcess
Darin Adler
Comment 4
2021-03-19 18:27:01 PDT
Comment on
attachment 423772
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=423772&action=review
> Source/WebCore/dom/AbortSignal.h:45 > + static Ref<AbortSignal> createAborted(ScriptExecutionContext&);
Why not name this abort to match the DOM public API?
Chris Dumez
Comment 5
2021-03-19 18:28:27 PDT
Comment on
attachment 423772
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=423772&action=review
>> Source/WebCore/dom/AbortSignal.h:45 >> + static Ref<AbortSignal> createAborted(ScriptExecutionContext&); > > Why not name this abort to match the DOM public API?
Because the abort() name is very confusing for such operation. Also, AbortSignal already has an abort() member function to actually abort the signal. I wish the spec had called this aborted() instead of abort()..
Sam Weinig
Comment 6
2021-03-20 18:32:46 PDT
Comment on
attachment 423772
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=423772&action=review
>>> Source/WebCore/dom/AbortSignal.h:45 >>> + static Ref<AbortSignal> createAborted(ScriptExecutionContext&); >> >> Why not name this abort to match the DOM public API? > > Because the abort() name is very confusing for such operation. Also, AbortSignal already has an abort() member function to actually abort the signal. I wish the spec had called this aborted() instead of abort()..
I think we should match the spec here and rename the other function to signalAbort, which is what the spec calls it. Even if we don’t love the names, it’s much easier if we match things when we can.
EWS
Comment 7
2021-03-22 05:00:30 PDT
commit-queue failed to commit
attachment 423772
[details]
to WebKit repository. To retry, please set cq+ flag again.
Chris Dumez
Comment 8
2021-03-22 08:22:57 PDT
(In reply to Sam Weinig from
comment #6
)
> Comment on
attachment 423772
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=423772&action=review
> > >>> Source/WebCore/dom/AbortSignal.h:45 > >>> + static Ref<AbortSignal> createAborted(ScriptExecutionContext&); > >> > >> Why not name this abort to match the DOM public API? > > > > Because the abort() name is very confusing for such operation. Also, AbortSignal already has an abort() member function to actually abort the signal. I wish the spec had called this aborted() instead of abort().. > > I think we should match the spec here and rename the other function to > signalAbort, which is what the spec calls it. Even if we don’t love the > names, it’s much easier if we match things when we can.
Ok, will update the name.
Chris Dumez
Comment 9
2021-03-22 08:32:03 PDT
Created
attachment 423885
[details]
Patch
EWS
Comment 10
2021-03-22 12:25:22 PDT
Committed
r274773
: <
https://commits.webkit.org/r274773
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 423885
[details]
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug