RESOLVED FIXED 233916
Safari Bug "no-cache" network error
https://bugs.webkit.org/show_bug.cgi?id=233916
Summary Safari Bug "no-cache" network error
Janos Wartig
Reported Tuesday, December 7, 2021 8:34:01 AM UTC
A fetch request on the page that sets the cache: "no-cache" will result in a network error when it is fetched by a Service Worker. The error that is thrown looks like this: TypeError: Request header field Cache-Control is not allowed by Access-Control-Allow-Headers I implemented a simple test page that reproduces the issue here: https://testjanos.app.baqend.com/ The test page registers a simple Service Worker which listens to fetch requests and tries to fetch them. It also includes the following script tag: <script> let options = { method: "POST", cache: "no-cache", mode: "cors", body: '{"weather":true}' }; fetch("https://dcinfos-cache.abtasty.com/v1/geoip", options); </script> Ways to reproduce: 1. Go to https://testjanos.app.baqend.com/ 2. Open Service Workers view (Developer -> Service Workers) 3. Refresh the page 4. Observe that resource https://dcinfos-cache.abtasty.com/v1/geoip could not be fetched due to above error (error prited to the Service Worker console) Is there any fix for this issue?
Attachments
Patch (9.09 KB, patch)
2021-12-08 02:32 PST, youenn fablet
no flags
youenn fablet
Comment 1 Wednesday, December 8, 2021 10:32:40 AM UTC
Chris Dumez
Comment 2 Wednesday, December 8, 2021 3:18:08 PM UTC
Comment on attachment 446342 [details] Patch r=me
EWS
Comment 3 Wednesday, December 8, 2021 4:01:03 PM UTC
Committed r286655 (244968@main): <https://commits.webkit.org/244968@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 446342 [details].
Radar WebKit Bug Importer
Comment 4 Wednesday, December 8, 2021 4:02:24 PM UTC
youenn fablet
Comment 5 Monday, March 14, 2022 12:01:31 PM UTC
*** Bug 236084 has been marked as a duplicate of this bug. ***
Note You need to log in before you can comment on or make changes to this bug.