[Webkit-unassigned] [Bug 247421] Content downloaded with fetch() API when Concent-Encoding: gzip is set is not decompressed

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Nov 4 01:23:01 PDT 2022


https://bugs.webkit.org/show_bug.cgi?id=247421

--- Comment #5 from jujjyl at gmail.com ---
I notice if I change emrun.py to override the MIME type of served test.data.gz from application/octet-stream to either "application/gzip" or something else random, like "application/vnd.oasis.opendocument.spreadsheet", then the test passes.

Commenting out the lines

#    self.send_header("Last-Modified", self.date_time_string(fs.st_mtime))
#    self.send_header('Cache-Control', 'no-cache, must-revalidate')
#    self.send_header('Connection', 'close')
#    self.send_header('Expires', '-1')
#    self.send_header('Access-Control-Allow-Origin', '*')
#    self.send_header('Cross-Origin-Opener-Policy', 'same-origin')
#    self.send_header('Cross-Origin-Embedder-Policy', 'require-corp')
#    self.send_header('Cross-Origin-Resource-Policy', 'cross-origin')

in emrun.py to remove potentially affecting headers, like COOP/COEP did not affect the scenario.

Oddly, also if I rename the test filename from 'test.data.gz' to e.g. 'test.data.jgz' (and also edit test.html to download the renamed file instead), then the test also passes. But when looking at the web console in the passed test, it prints

[Warning] Fetch Response headers: (test.html, line 10)
[Log] access-control-allow-origin: * (test.html, line 12)
[Log] cache-control: no-cache, must-revalidate (test.html, line 12)
[Log] connection: close (test.html, line 12)
[Log] content-encoding: gzip (test.html, line 12)
[Log] content-length: 25098 (test.html, line 12)
[Log] content-type: application/octet-stream (test.html, line 12)

so here the file did still have content-type application/octet-stream in it.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20221104/ef3452cd/attachment-0001.htm>


More information about the webkit-unassigned mailing list