Re: [w3c/ServiceWorker] SharedWorker script interception after redirects (#1289)

Thanks wanderview for fixing my flawed test.

I notice now that the Fetch spec treats redirects from service worker vs network differently also. Is the below summary now accurate?

The spec says:
1. The initial request gets intercepted. Once any redirect comes from network (as opposed to from a service worker), that redirect and subsequent redirects are not intercepted.
2. The final service worker that gets a fetch event (or would have, in the case of a non-fetch event worker) becomes the controller of the resulting service worker client.

Assuming network redirects only, that means the spec says:
1. Only the initial request gets intercepted.
2. The initial request URL is used to determine the controller.

Chrome does this:
1. Each redirect is intercepted.
2. The final response URL is used to determine the controller.

Firefox does what the spec says. So assuming network redirects only, it does (as above):
1. Only the initial request gets intercepted.
2. The initial request URL is used to determine the controller.

I briefly tested service worker generated redirects and Firefox seems to treat those the same as network redirects, but I may be missing something.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/issues/1289#issuecomment-375152701

Received on Thursday, 22 March 2018 01:54:29 UTC