<div dir="ltr"><div><div>FWIW <a href="https://github.com/pypa/pip/pull/3146">https://github.com/pypa/pip/pull/3146</a> exists for the wheel cache.<br><br></div>Concerning http cache and <a href="https://github.com/ionrock/cachecontrol">https://github.com/ionrock/cachecontrol</a> the main issue is that the cached request is not present in the cache. We only have a "hash -> response" mapping.<br></div>I plan to make a PR asking to also keep the request for introspection and move to a "hash -> (request, response)" mapping.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Oct 14, 2015 at 11:01 PM, Glyph Lefkowitz <span dir="ltr"><<a href="mailto:glyph@twistedmatrix.com" target="_blank">glyph@twistedmatrix.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><span class=""><br><div><blockquote type="cite"><div>On Oct 14, 2015, at 1:04 PM, Donald Stufft <<a href="mailto:donald@stufft.io" target="_blank">donald@stufft.io</a>> wrote:</div><br><div><span style="font-family:Menlo-Regular;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">Generally within 60-120 seconds it’s available in mirrors (most of them resync once a minute). If anyone has downloaded it then they will have pretty much permanently cached the package, first in the download cache and then again in the wheel cache (assuming it wasn’t a wheel already, and they had that enabled). The original package was NumPy. It had 30,982 downloads in the last day, so we can average that out to 1290 downloads an hour or 21 downloads a minute. If it takes you two minutes to notice it and delete it, then there are ~40 people who already have the original version cached and who will not notice the updated version.</span><br style="font-family:Menlo-Regular;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"></div></blockquote></div><br></span><div>While I don't think PyPI should allow modification of uploaded packages necessarily, I do think that Pip's caching is (A) too aggressive and (B) too opaque.  For example:</div><div><br></div><div><a href="https://github.com/pypa/pip/issues/3127" target="_blank">https://github.com/pypa/pip/issues/3127</a></div><div><a href="https://github.com/pypa/pip/issues/3034" target="_blank">https://github.com/pypa/pip/issues/3034</a></div><div><a href="https://github.com/pypa/pip/issues/3025" target="_blank">https://github.com/pypa/pip/issues/3025</a></div><div><a href="https://github.com/pypa/pip/issues/2908" target="_blank">https://github.com/pypa/pip/issues/2908</a></div><div><a href="https://github.com/pypa/pip/issues/2882" target="_blank">https://github.com/pypa/pip/issues/2882</a></div><div><br></div><div>etc, etc.</div><div><br></div><div>I know there are some directories platform-specific directories I can delete, but almost once a day I want a command like `pip cache show´ which can show me what is cached and when/where it was built, `pip cache clear´ or `pip cache remove twisted´ or `pip cache remove cffi>=1.0´.  I don't want to have to care if it's in the HTTP cache or the wheel cache, or how it got there; I also don't want to have to bust a ~200 megabyte cache that saves me hours a day just because there's one bad entry in there.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>-glyph</div><div><br></div></font></span></div><br>_______________________________________________<br>
Distutils-SIG maillist  -  <a href="mailto:Distutils-SIG@python.org">Distutils-SIG@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/distutils-sig" rel="noreferrer" target="_blank">https://mail.python.org/mailman/listinfo/distutils-sig</a><br>
<br></blockquote></div><br></div>