[wpt-sync] Sync PR 63900 - WebKit export of https://bugs.webkit.org/show_bug.cgi?id=328102
Categories
(Testing :: web-platform-tests, task, P4)
Tracking
(firefox162 fixed)
| Tracking | Status | |
|---|---|---|
| firefox162 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 63900 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/63900
Details from upstream follow.
Anne van Kesteren <annevk@annevk.nl> wrote:
WebKit export of https://bugs.webkit.org/show_bug.cgi?id=328102
WebKit export from bug: Blob'<!---->s text(<!---->)<!----> should decode its data as it arrives
<pre>
Blob's text() should decode its data as it arrivesSince <a href="https://commits.webkit.org/324134@main">324134@main</a>, Blob's text() reads the whole blob into an ArrayBuffer and then decodes it as
UTF-8. FileReaderLoader allocates that ArrayBuffer at the blob's full size when the load starts,
zero-fills it, copies each chunk into it, and only decodes once the last chunk has arrived.Add FileReaderLoader::ReadAsUTF8Text, which passes each chunk to a TextResourceDecoder that always
uses UTF-8 and appends the result to a StringBuilder. Blob's text() no longer allocates or
zero-fills a buffer of the blob's size, and memory grows with the decoded text as it arrives rather
than all being allocated up front. Peak memory is about the same as before: each decoded chunk is
still copied into the StringBuilder, and the StringBuilder grows by reallocating. Reserving its
capacity from the blob's size would avoid that for ASCII, but would use more memory than before for
other text, since StringBuilder doubles its capacity when it widens to 16-bit.For this to work, TextResourceDecoder has to handle a byte order mark split across chunks. When the
first chunk was shorter than three bytes, decode() passed it to the codec right away, so a byte
order mark that continued in the next chunk was missed: a UTF-8 one was decoded as U+FEFF, and data
after a UTF-16 one was decoded as UTF-8. It now holds on to the data until there is enough to tell
whether it starts with a byte order mark. This also fixes responseText and JSON responses of
XMLHttpRequest, and EventSource, which decode their data as it arrives too.The network process sends each blob part that is a blob itself as its own chunk, so the new Blob
subtests split a byte order mark and a multi-byte sequence across such parts. The new XMLHttpRequest
and EventSource tests use xhr/resources/content-in-chunks.py, added in <a href="https://commits.webkit.org/318297@main">318297@main</a>, to split the
byte order mark across network chunks.WebKit-Bug: <a href="https://bugs.webkit.org/show_bug.cgi?id=328102">https://bugs.webkit.org/show_bug.cgi?id=328102</a>
</pre>
| Assignee | ||
Updated•1 month ago
|
| Assignee | ||
Updated•1 month ago
|
| Assignee | ||
Comment 1•1 month ago
|
||
Pushed to try (stability) https://treeherder.mozilla.org/jobs?repo=try&landoInstance=lando-prod-2025&landoCommitID=109381
| Assignee | ||
Comment 2•1 month ago
|
||
CI Results
Ran 10 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 574 tests and 1 subtests
Status Summary
Firefox
OK : 4[GitHub] 565[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-windows11-64-25h2-debug] 567[Gecko-windows11-32-25h2-debug, Gecko-windows11-64-25h2-opt] 568[Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 569[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt]
PASS : 2[Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt] 32[GitHub] 3020[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-windows11-64-25h2-debug] 3027[Gecko-windows11-32-25h2-debug, Gecko-windows11-64-25h2-opt] 3028[Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview] 3029[Gecko-linux2404-64-debug, Gecko-linux2404-64-opt]
FAIL : 8[GitHub] 76[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
TIMEOUT: 4
Chrome
OK : 4
PASS : 28
FAIL : 12
TIMEOUT: 4
Safari
OK : 4
PASS : 28
FAIL : 12
TIMEOUT: 4
Links
Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base
Details
New Tests That Don't Pass
- /xhr/open-url-multi-window-4.htm [wpt.fyi]:
SKIP - /FileAPI/blob/Blob-textStream.any.html [wpt.fyi]
- textStream method existence:
FAIL - Blob.textStream() basic functionality:
FAIL - Blob.textStream() with empty blob:
FAIL - Blob.textStream() with multi-part blob:
FAIL - Blob.textStream() ignores type charset (UTF-16LE):
FAIL - Blob.textStream() ignores invalid type charset (invalid-charset):
FAIL - Blob.textStream() ignores type charset (iso-8859-1):
FAIL - Blob.textStream() can be called multiple times:
FAIL
- textStream method existence:
- /FileAPI/blob/Blob-textStream.any.sharedworker.html [wpt.fyi]
- textStream method existence:
FAIL - Blob.textStream() basic functionality:
FAIL - Blob.textStream() with empty blob:
FAIL - Blob.textStream() with multi-part blob:
FAIL - Blob.textStream() ignores type charset (UTF-16LE):
FAIL - Blob.textStream() ignores invalid type charset (invalid-charset):
FAIL - Blob.textStream() ignores type charset (iso-8859-1):
FAIL - Blob.textStream() can be called multiple times:
FAIL
- textStream method existence:
- /FileAPI/blob/Blob-textStream.any.serviceworker.html [wpt.fyi]
- textStream method existence:
FAIL - Blob.textStream() basic functionality:
FAIL - Blob.textStream() with empty blob:
FAIL - Blob.textStream() with multi-part blob:
FAIL - Blob.textStream() ignores type charset (UTF-16LE):
FAIL - Blob.textStream() ignores invalid type charset (invalid-charset):
FAIL - Blob.textStream() ignores type charset (iso-8859-1):
FAIL - Blob.textStream() can be called multiple times:
FAIL
- textStream method existence:
- /FileAPI/blob/Blob-textStream.any.worker.html [wpt.fyi]
- textStream method existence:
FAIL - Blob.textStream() basic functionality:
FAIL - Blob.textStream() with empty blob:
FAIL - Blob.textStream() with multi-part blob:
FAIL - Blob.textStream() ignores type charset (UTF-16LE):
FAIL - Blob.textStream() ignores invalid type charset (invalid-charset):
FAIL - Blob.textStream() ignores type charset (iso-8859-1):
FAIL - Blob.textStream() can be called multiple times:
FAIL
- textStream method existence:
- /eventsource/eventsource-constructor-non-same-origin.window.html [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-windows11-64-25h2-debug] - /eventsource/format-bom-split.any.worker.html [wpt.fyi]:
TIMEOUT(Chrome:TIMEOUT, Safari:TIMEOUT)- EventSource: byte order mark split across chunks:
TIMEOUT(Chrome:TIMEOUT, Safari:TIMEOUT)
- EventSource: byte order mark split across chunks:
- /eventsource/format-bom-split.any.html [wpt.fyi]:
TIMEOUT(Chrome:TIMEOUT, Safari:TIMEOUT)- EventSource: byte order mark split across chunks:
TIMEOUT(Chrome:TIMEOUT, Safari:TIMEOUT)
- EventSource: byte order mark split across chunks:
- /xhr/access-control-preflight-credential-async.htm [wpt.fyi]
- CORS async request with URL credentials:
FAIL
- CORS async request with URL credentials:
- /xhr/access-control-preflight-credential-sync.htm [wpt.fyi]
- CORS sync request with URL credentials:
FAIL
- CORS sync request with URL credentials:
- /xhr/event-timeout.any.worker.html [wpt.fyi]:
OK[Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview] - /xhr/getallresponseheaders-after-reuse.html [wpt.fyi]
- getAllResponseHeaders() must not return the previous response's headers:
FAIL
- getAllResponseHeaders() must not return the previous response's headers:
- /xhr/getallresponseheaders.htm [wpt.fyi]
- XMLHttpRequest: getAllResponseHeaders() 2:
FAIL - XMLHttpRequest: getAllResponseHeaders() 3:
FAIL - XMLHttpRequest: getAllResponseHeaders() 5:
FAIL - XMLHttpRequest: getAllResponseHeaders() 6:
FAIL
- XMLHttpRequest: getAllResponseHeaders() 2:
- /xhr/getresponseheader.any.worker.html [wpt.fyi]
- getResponseHeader('content-length') expects 0, 0:
FAIL - getResponseHeader('double-trouble') expects , :
FAIL - getResponseHeader('heya') expects , , 1, , , 2:
FAIL - getResponseHeader('www-authenticate') expects 1, 2, 3, 4:
FAIL
- getResponseHeader('content-length') expects 0, 0:
- /xhr/getresponseheader.any.html [wpt.fyi]
- getResponseHeader('content-length') expects 0, 0:
FAIL - getResponseHeader('double-trouble') expects , :
FAIL - getResponseHeader('heya') expects , , 1, , , 2:
FAIL - getResponseHeader('www-authenticate') expects 1, 2, 3, 4:
FAIL
- getResponseHeader('content-length') expects 0, 0:
- /xhr/open-url-multi-window-6.htm [wpt.fyi]
- XMLHttpRequest: open() in document that is not fully active (but may be active) should throw:
FAIL
- XMLHttpRequest: open() in document that is not fully active (but may be active) should throw:
- /xhr/overridemimetype-blob.html [wpt.fyi]
-
- MIME types need to be parsed and serialized: TEXT/HTML;CHARSET=GBK:
FAIL
- MIME types need to be parsed and serialized: TEXT/HTML;CHARSET=GBK:
-
- MIME types need to be parsed and serialized: text/html;charset= ";charset=GBK:
FAIL
- MIME types need to be parsed and serialized: text/html;charset= ";charset=GBK:
-
- MIME types need to be parsed and serialized: text/html;charset=";charset=foo";charset=GBK:
FAIL
- MIME types need to be parsed and serialized: text/html;charset=";charset=foo";charset=GBK:
-
- MIME types need to be parsed and serialized: text/html;charset=";charset=GBK:
FAIL
- MIME types need to be parsed and serialized: text/html;charset=";charset=GBK:
-
- MIME types need to be parsed and serialized: !#$%&'+-.^_
|~0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz/!#$%&'*+-.^_|~0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz;!#$%&'+-.^_|~0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz=!#$%&'*+-.^_|~0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz:FAIL
- MIME types need to be parsed and serialized: !#$%&'+-.^_
-
- MIME types need to be parsed and serialized: x/x;x=" !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_
abcdefghijklmnopqrstuvwxyz{|}~ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ":FAIL`
- MIME types need to be parsed and serialized: x/x;x=" !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_
-
- MIME types need to be parsed and serialized: text/html;test=ÿ;charset=gbk:
FAIL
- MIME types need to be parsed and serialized: text/html;test=ÿ;charset=gbk:
-
- /xhr/responseurl-after-abort.any.html [wpt.fyi]
- abort() during HEADERS_RECEIVED clears responseURL:
FAIL - abort() during LOADING clears responseURL:
FAIL
- abort() during HEADERS_RECEIVED clears responseURL:
- /xhr/responseurl-after-abort.any.worker.html [wpt.fyi]
- abort() during HEADERS_RECEIVED clears responseURL:
FAIL - abort() during LOADING clears responseURL:
FAIL - abort() during DONE clears responseURL (async):
FAIL - abort() during DONE clears responseURL (sync):
FAIL - responseURL reflects the new response after abort() and reuse:
FAIL
- abort() during HEADERS_RECEIVED clears responseURL:
- /xhr/send-response-event-order.htm [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt],SKIP[Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt] - /xhr/send-response-upload-event-progress.htm [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt],SKIP[Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt] - /xhr/send-usp.any.worker.html [wpt.fyi]
- XMLHttpRequest.send(URLSearchParams): POST uses the URLSearchParams MIME type when no Content-Type was set:
FAIL - XMLHttpRequest.send(URLSearchParams): POST replaces the charset parameter of an author-set Content-Type:
FAIL
- XMLHttpRequest.send(URLSearchParams): POST uses the URLSearchParams MIME type when no Content-Type was set:
- /xhr/split-byte-order-mark.any.worker.html [wpt.fyi]
- responseText strips a UTF-8 byte order mark split across chunks:
FAIL(Chrome:FAIL, Safari:FAIL) - responseText uses a UTF-16LE byte order mark split across chunks:
FAIL(Chrome:FAIL, Safari:FAIL) - responseText does not strip a UTF-8 byte order mark in a later chunk:
FAIL(Chrome:FAIL, Safari:FAIL) - JSON response strips a UTF-8 byte order mark split across chunks:
FAIL(Chrome:FAIL, Safari:FAIL)
- responseText strips a UTF-8 byte order mark split across chunks:
- /xhr/split-byte-order-mark.any.html [wpt.fyi]
- responseText strips a UTF-8 byte order mark split across chunks:
FAIL(Chrome:FAIL, Safari:FAIL) - responseText uses a UTF-16LE byte order mark split across chunks:
FAIL(Chrome:FAIL, Safari:FAIL) - responseText does not strip a UTF-8 byte order mark in a later chunk:
FAIL(Chrome:FAIL, Safari:FAIL) - JSON response strips a UTF-8 byte order mark split across chunks:
FAIL(Chrome:FAIL, Safari:FAIL)
- responseText strips a UTF-8 byte order mark split across chunks:
- /xhr/sync-xhr-and-window-onload.html [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview] - /xhr/sync-xhr-supported-by-permissions-policy.tentative.html [wpt.fyi]
- document.permissionsPolicy.features should advertise sync-xhr.:
FAIL
- document.permissionsPolicy.features should advertise sync-xhr.:
- /xhr/xhr-authorization-redirect.any.html [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-windows11-64-25h2-debug] - /xhr/xhr-timeout-longtask.any.html [wpt.fyi]
- Long tasks should not trigger load timeout:
FAIL
- Long tasks should not trigger load timeout:
- /xhr/xmlhttprequest-sync-default-permissions-policy.tentative.sub.html [wpt.fyi]
- permissions policy "sync-xhr" can be disabled in cross-origin iframes using "allow" attribute.:
FAIL - permissions policy "sync-xhr" can be disabled in same-origin iframes using "allow" attribute.:
FAIL
- permissions policy "sync-xhr" can be disabled in cross-origin iframes using "allow" attribute.:
Tests Disabled in Gecko Infrastructure
- /xhr/open-url-multi-window-4.htm [wpt.fyi]:
SKIPlinked bug:Bug 1366966 - /eventsource/eventsource-constructor-non-same-origin.window.html [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-windows11-64-25h2-debug] - /xhr/event-timeout.any.worker.html [wpt.fyi]:
OK[Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview] - /xhr/send-response-event-order.htm [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt],SKIP[Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt] - /xhr/send-response-upload-event-progress.htm [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt],SKIP[Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt] - /xhr/sync-xhr-and-window-onload.html [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview] - /xhr/xhr-authorization-redirect.any.html [wpt.fyi]:
OK[Gecko-android-em-14-x86_64-lite-opt-geckoview,Gecko-android-em-14-x86_64-opt-geckoview,Gecko-linux2404-64-debug,Gecko-linux2404-64-opt,Gecko-windows11-32-25h2-debug,Gecko-windows11-64-25h2-opt],SKIP[Gecko-android-em-14-x86_64-debug-geckoview,Gecko-windows11-64-25h2-debug]
Comment 4•24 days ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/2c0572f20255
https://hg.mozilla.org/mozilla-central/rev/ccf56f5b40f8
Description
•