Closed machawk1 closed 11 years ago
Potentially call chrome.tabs.reload({reloadProperties: {bypassCache: true}}); to potentially get around this though currently we're just modifying the URI before the request goes out, not reloading the tab.
To check I understand what's going on: Is the issue that, if a URL has been cached locally (within the browser itself), then the browser does not re-launch a request, i.e. the handler on chrome.webRequest.onBeforeRequest is never called?
There is also this function, although it is perhaps a little too aggressive:
http://developer.chrome.com/extensions/browsingData.html#method-removeCache
removeCache() is a big hammer. Regarding this issue, I've created a MWE that does NOT validate this issue, i.e., cached resource requests still appear to go through the onBeforeRequest handler. For some reason, during the request processing with the Memento logic, some resources requests never hit the handler code.
Vs. the MWE, this might be that tachyon is not returning what is expected in the handler, preventing the other resources from hitting the same handlers.
Can you outline the steps to reproduce this issue? And, what does MWE mean?
MWE = Minimum Work Example, a bare bones logic-stripped-out code I used to check which handlers were being called and for what resources. The bare bones MWE Chrome Extension has all resources hitting the handlers regardless of whether they're cached. The tachyon seems to not send requests for the images (for example) through the negotiation process but the initial page resolves correctly.
I am using http://odusource.cs.odu.edu/hello as my basis URL, as it specifies a custom timegate in the HTTP headers. I am activating time travel in the extension by selecting a date then navigating to this page in the browser and watching the log.
Not sure if this has already been tried, but I am able to overcome the caching problem by using the handlerBehaviorChanged() method.
http://developer.chrome.com/extensions/webRequest.html#caching http://developer.chrome.com/extensions/webRequest.html#method-handlerBehaviorChanged
This is by design in Chrome. I need some way to prevent the cache from being accessed when in Memento Mode.