New issue
Advanced search Search tips

Issue 720918 link

Starred by 3 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 655479



Sign in to add a comment

Failures in WPT's service-workers/cache-storage/*/cache-matchAll.https.html

Project Member Reported by jsb...@chromium.org, May 10 2017

Issue description

window, worker, and serviceworker variants all fail with:

*/cache-matchAll.https-expected.txt:FAIL Cache.matchAll with responses containing "Vary" header assert_equals: Cache.matchAll should match the entire header if a vary header is present in both the query and cached requests. expected 1 but got 0
*/cache-matchAll.https-expected.txt:FAIL Cache.matchAll with multiple vary pairs assert_equals: Cache.matchAll should support multiple vary request/response pairs. expected 3 but got 1

Determine if this is a legitimate bug or if the test is broken (i.e. compare spec and test, and see what Firefox does here)

 

Comment 1 by jsb...@chromium.org, Jul 20 2017

Ali from MSFT reports this behavior differs between Firefox and Chrome - could be the same issue:

async function test(){
	await self.caches.delete('testCache');
  const cache = await self.caches.open('testCache');
  const request1headers = {};
  request1headers['FooHeader'] = '1';
  const request1 = new Request('foo.htm', {
  	headers: request1headers
  });
  const response1Headers = {};
  response1Headers['Vary'] = 'FooHeader';
  const response1 = new Response('foo1', { headers : response1Headers });
  await cache.put(request1, response1);
  
  const request2headers = {};
  request2headers['FooHeader'] = '2';
  const request2 = new Request('foo.htm', {
  	headers: request2headers
  });
  const response2Headers = {};
  response1Headers['Vary'] = 'FooHeader';
  const response2 = new Response('foo2', { headers : response2Headers });
	await cache.put(request2, response2);
  
  alert((await cache.keys()).length);
}

test();

It seems like .put silently fails for anything with a vary header, which is kinda odd.

https://jsbin.com/qobutey/edit?js,console - Firefox is doing the expected thing here.

Firefox logs:

"2 requests"
"1,3"

…because the 2nd put'd item is overwritten by the third.

Here's a further-reduced test https://jsbin.com/2b198f2fa478bea3fd1b31df21e89758/edit?js,console.

It should log 1 & 1. Chrome logs 1 & 0, since it fails to cache the Vary response.
Project Member

Comment 3 by sheriffbot@chromium.org, Aug 16

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue.

Sorry for the inconvenience if the bug really should have been left as Available.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Status: Available (was: Untriaged)
The further-reduced test in Comment 2 logs 1 & 1 on Chrome canary 70.0.3526.0. However, the first test there still logs "1 requests", and the failure expectations in the original report appear to be valid.

Sign in to add a comment