@@ -2123,6 +2123,11 @@ Unless stated otherwise, it is false.
2123
2123
2124
2124
<p class=note> This is for exclusive use by HTML's navigate algorithm. [[!HTML]]
2125
2125
2126
+ <p> A <a for=/>request</a> has an associated <dfn export for=request>navigation
2127
+ id</dfn> (a string). Unless stated otherwise, it is null.
2128
+
2129
+ <p class=note> This is for exclusive use by HTML's navigate algorithm. [[!HTML]]
2130
+
2126
2131
<p> A <a for=/>request</a> has an associated boolean <dfn export for=request>render-blocking</dfn> .
2127
2132
Unless stated otherwise, it is false.
2128
2133
@@ -2164,6 +2169,15 @@ otherwise, it is unset.
2164
2169
<a for=request>done flag</a> , and <a for=request>timing allow failed flag</a> are used as
2165
2170
bookkeeping details by the <a for=/>fetch</a> algorithm.
2166
2171
2172
+ <p> A <a for=/>request</a> has an associated
2173
+ <dfn export for=request id=concept-request-id>request id</dfn> which is a unique
2174
+ string automatically set when the <a for=/>request</a> is created.
2175
+
2176
+ Note: the [=request/request id=] is used by WebDriver-BiDi. It remains constant
2177
+ across all requests resulting from a redirect of an initial request. When a
2178
+ request is [=request/cloned=] , the created request gets a unique
2179
+ [=request/request id=] . [[!WEBDRIVER-BIDI]]
2180
+
2167
2181
<hr>
2168
2182
2169
2183
<p> A <dfn export>subresource request</dfn> is a <a for=/>request</a>
@@ -2240,7 +2254,10 @@ is to return the result of <a>serializing a request origin</a> with <var>request
2240
2254
2241
2255
<ol>
2242
2256
<li><p> Let <var> newRequest</var> be a copy of <var> request</var> , except for its
2243
- <a for=request>body</a> .
2257
+ <a for=request>body</a> and <a for=request>request id</a> .
2258
+
2259
+ <li><p> Let <var> newRequest's</var> <a for=request>request id</a> be a new
2260
+ unique string.
2244
2261
2245
2262
<li><p> If <var> request</var> 's <a for=request>body</a> is non-null, set <var>newRequest</var>' s
2246
2263
<a for=request>body</a> to the result of <a lt=clone for=body>cloning</a> <var> request</var> 's
@@ -4779,6 +4796,11 @@ steps:
4779
4796
<a for=request>URL</a> , <var> fetchParams</var> 's <a for="fetch params">request</a>' s
4780
4797
<a for=request>initiator type</a> , <var> global</var> , <var> cacheState</var> ,
4781
4798
<var> bodyInfo</var> , and <var> responseStatus</var> .
4799
+
4800
+ <li><p> If <var> response</var> is a <a>network error</a> , run
4801
+ the <a>WebDriver BiDi fetch error</a> steps with <var> request</var> . Otherwise
4802
+ run the <a>WebDriver BiDi response completed</a> steps with
4803
+ <var> request</var> and <var> response</var> .
4782
4804
</ol>
4783
4805
4784
4806
<li>
@@ -5129,6 +5151,13 @@ these steps:
5129
5151
<a>filtered response</a> ; otherwise to <var> response</var> 's
5130
5152
<a for="filtered response">internal response</a> .
5131
5153
5154
+ <!-- Service Workers is responsible for emmitting the WebDriver BiDi
5155
+ request events in this case. That's necessary to ensure that the events are
5156
+ only generated if the service worker will handle the fetch, and to get the
5157
+ correct event ordering in the case of network fallback -->
5158
+ <li><p> Run the [=WebDriver BiDi response started=] steps with
5159
+ <var> request</var> and <var> response</var> .
5160
+
5132
5161
<li>
5133
5162
<p> If one of the following is true
5134
5163
@@ -5663,6 +5692,10 @@ run these steps:
5663
5692
<p class=note> This intentionally does not depend on <var> httpRequest</var> 's
5664
5693
<a for=request>credentials mode</a> .
5665
5694
5695
+ <!-- After this point the request is not further modified before being either
5696
+ retrieved from the cache or sent -->
5697
+ <li><p> Run the <a>WebDriver BiDi before request sent</a> steps with <var> request</var> .
5698
+
5666
5699
<li><p> Set <var> httpCache</var> to the result of <a>determining the HTTP cache partition</a> ,
5667
5700
given <var> httpRequest</var> .
5668
5701
@@ -5758,6 +5791,8 @@ run these steps:
5758
5791
<li><p> <a>If aborted</a> , then return the <a for=/>appropriate network error</a> for
5759
5792
<var> fetchParams</var> .
5760
5793
5794
+ <li><p> If <var> response</var> is not null, run the <a>WebDriver BiDi response
5795
+ started</a> steps with <var> request</var> and <var> response</var> .
5761
5796
5762
5797
<!-- If response is still null, we require a forwarded request. -->
5763
5798
<li>
@@ -6021,6 +6056,9 @@ optional boolean <var>forceNewConnection</var> (default false), run these steps:
6021
6056
6022
6057
<li><p> Wait until all the HTTP response headers are transmitted.
6023
6058
6059
+ <li><p> Run the [=WebDriver BiDi response started=] steps with
6060
+ |request| and |response|.
6061
+
6024
6062
<li><p> Let <var> status</var> be the HTTP response's status code.
6025
6063
6026
6064
<li>
0 commit comments