test-infra icon indicating copy to clipboard operation
test-infra copied to clipboard

Adjust index page `Cache-Control` headers

Open edmorley opened this issue 11 months ago • 4 comments

This changes the Cache-Control value for index pages from: no-cache,no-store,must-revalidate

...to: max-age=600, public

In order to allow the pages to be cached for up to 10 minutes.

The new value was chosen so that it matches that returned for PyPI index pages:

$ curl -sSI https://pypi.org/simple/ | rg cache-control
cache-control: max-age=600, public

For explanations of the directives, see: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control#response_directives

Fixes pytorch/pytorch#130571.

edmorley avatar Jan 18 '25 20:01 edmorley

@edmorley is attempting to deploy a commit to the Meta Open Source Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Jan 18 '25 20:01 vercel[bot]

Hi @edmorley Looks good. lets also keep explicit must-revalidate after max-age=600 is reached

atalman avatar Jan 20 '25 20:01 atalman

@atalman Thank you for the initial review. I've made the suggested changes and rebased on latest main :-)

edmorley avatar Feb 03 '25 08:02 edmorley

@atalman Hi! I don't suppose you have time for a re-review? :-)

edmorley avatar Feb 18 '25 08:02 edmorley

@atalman Hi! Your review comments have been addressed (back in Feb), and I've just rebased again on main.

I don't suppose you could re-review and merge?

Thanks :-)

edmorley avatar Jul 08 '25 09:07 edmorley

@atalman @edmorley Hi guys, can I help here to get this deployed?

mo22 avatar Aug 20 '25 07:08 mo22