Re: [whatwg/fetch] Add abort reason to abort fetch (PR #1343)

@annevk commented on this pull request.



> @@ -5789,8 +5805,8 @@ optional boolean <var>forceNewConnection</var> (default false), run these steps:
        <li><p>Set <var>response</var>'s <a for=response>aborted flag</a>.
 
        <li><p>If <var>stream</var> is <a for=ReadableStream>readable</a>,
-       <a for=ReadableStream>error</a> <var>stream</var> with an
-       "<code><a exception>AbortError</a></code>" {{DOMException}}.
+       <a for=ReadableStream>error</a> <var>stream</var> with <var>fetchParams</var>'s
+       <a for="fetch params">controller</a>'s <a for="fetch controller">serialized abort reason</a>.

We'll need to deserialize this first.

> @@ -7784,9 +7803,21 @@ method steps are:
   <ol>
    <li><p>If <var>locallyAborted</var> is true, terminate these substeps.
 
-   <li><p>If <var>response</var>'s <a for=response>aborted flag</a> is set, then <a>abort fetch</a>
-   with <var>p</var>, <var>request</var>, and <var>responseObject</var>, and terminate these
-   substeps.
+   <li><p>If <var>response</var>'s <a for=response>aborted flag</a> is set, then:

Yeah, once the aborted flag is set the controller should also be aborted. I hope those cannot get out-of-sync... cc @noamr 

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/pull/1343#pullrequestreview-1125663420
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/fetch/pull/1343/review/1125663420@github.com>

Received on Thursday, 29 September 2022 16:41:44 UTC