Summary: | Buggy caching of .js/.css resources | ||
---|---|---|---|
Product: | WebKit | Reporter: | Kyle Simpson <getify> |
Component: | New Bugs | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED DUPLICATE | ||
Severity: | Normal | CC: | ap |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | PC | ||
OS: | Windows XP | ||
URL: | http://test.getify.com/chrome-cache-bug-2/ |
Description
Kyle Simpson
2010-03-08 15:22:18 PST
It might very well be a duplicate of 30862 in terms of the actual underlying functionality issues, but I can say specifically that my bug has some different symptoms than 30862 is listing. Mine is related to behavior of resources that load AFTER the regular page is finished loading (on-demand resources).30862 seems to be referring to resources that are loaded during page load. In my test, you can actually see that resources loaded at page load time ("script1.js" and "css1.css") behave just fine with respect to the cache. It's only the "script2.js" and "css2.css" that behave incorrectly, and it appears it's because they are loaded later, on-demand, after a 3 second delay. Also, as my bug demonstrates, this incorrect (too aggressive) caching actually causes the resources to be kept around in some sort of in-memory cache EVEN after the actual cache is manually cleared. 30862 seems to suggest the opposite, that clearing the cache fixes their problem. I should also point out that this DOES in fact also affect both Firefox and Chrome. My original supposition was that it was only webkit related, but it appears to be more widespread than that. That's all very good information, thanks! It makes the behavior look more like correct one though - it would be great if you could rephrase the report to make it clear what exactly is the bug here. Note that we usually try to mimic Firefox loading behavior when in doubt. Please also specify how you are emptying the cache - we have two ways for doing that in Safari menu, and two more in Debug menu, which is unfortunate. So, FWIW, Safari and Firefox differ from Chrome on one particular point: In Chrome, even if you clear the cache, it keeps the dynamically loaded items around persistently, until you navigate away and come back. In Safari and FF it appears that it DOES re-download if you clear the cache. However, *all 3* browsers have the problem that if you do a shift-refresh, it doesn't re-validate the items that are loaded later on-demand. So those get incorrectly loaded from cache. Perhaps you may say this is intentional by design. But what is the point of allowing shift-refresh to reload a page's resources if in fact it only reloads *some* of a page's resources (those that are loaded immediately at page-load)? Just left a comment over on Bug 30862: https://bugs.webkit.org/show_bug.cgi?id=30862#c12 I now feel that this bug *is* a duplicate of 30862, provided that 30862 is taken in the proper scope as I described in that comment. *** This bug has been marked as a duplicate of bug 30862 *** |