Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only revalidate /simple/ pages instead of caching for 10 minutes #5791

Merged
merged 1 commit into from
Sep 18, 2018

Conversation

dstufft
Copy link
Member

@dstufft dstufft commented Sep 18, 2018

Sets the max-age on a request to /simple/ to 0, which will bypass the cache during the request phase, but will still utilize it for creating and fulfilling conditional HTTP requests. This will allow us to no longer confuse end users when they do pip install ... && twine upload ... && pip install .. while still minimizing bandwidth as much as we can.

This will increase the time for repeat pip installs, since we'll have to do a round trip for the conditional request instead of serving directly out of the cache, however that is the common case anyways (we only cached these responses for up to 10 minutes anyways) so it's not likely to be a very big deal, while the confusion caused by the cache was a persistent problem.

Fixes #5670

@dstufft
Copy link
Member Author

dstufft commented Sep 18, 2018

Hmm, @pradyunsg it looks like mypy is broken? I don't think my change could have caused that so I'm guessing it's broken on master at the moment?

@pradyunsg
Copy link
Member

pradyunsg commented Sep 18, 2018

It is. There's been a new mypy release and my bodge isn't working anymore.

Let's go ahead and pin to the older release (0.620) for now. I get an email on every mypy release from Travis CI anyway -- I'll just swap that out with https://libraries.io.

@pradyunsg pradyunsg added C: cache Dealing with cache and files in it T: bugfix labels Sep 18, 2018
@pradyunsg pradyunsg added this to the 18.1 milestone Sep 18, 2018
@pradyunsg
Copy link
Member

@dstufft #5792 does that.

@pradyunsg
Copy link
Member

master is green.

@dstufft dstufft merged commit 6296766 into pypa:master Sep 18, 2018
@dstufft dstufft deleted the zero-cache-time-simple branch September 18, 2018 14:24
@lock
Copy link

lock bot commented Jun 1, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot added the auto-locked Outdated issues that have been locked by automation label Jun 1, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jun 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
auto-locked Outdated issues that have been locked by automation C: cache Dealing with cache and files in it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Local HTTP cache is confusing for package maintainers
2 participants