Skip to content
This repository was archived by the owner on Nov 15, 2017. It is now read-only.
This repository was archived by the owner on Nov 15, 2017. It is now read-only.

CSS/img pulled from browser cache won't be reported in matrix #93

Open

Description

@gorhill

That's because there is no onBeforeRequest() triggered for these. That sucks.

Potential fix: just like for scripts/plugins, inspect the DOM and collect occurrences from there as well.

Activity

  1. gorhill commented on Jan 17, 2014

    @gorhill
    OwnerAuthor

    I started a fix for this, and now one of the side effect of the solution is that requests might be reported twice in the log, because one request might have been recorded through onBeforeRequest() and another through DOM analysis.

    Need to find a way to mitigate this.

  2. gorhill commented on Jan 18, 2014

    @gorhill
    OwnerAuthor

    I should give a try to webRequest.onResponseStarted or webRequest.onCompleted and check the details.fromCache flag, looks promising.

  3. gorhill commented on Jan 18, 2014

    @gorhill
    OwnerAuthor

    By the way, a good way to verify the bug is:

    • Go to http://arstechnica.com/
    • Open the Statistics page and narrow the log to http://arstechnica.com/
    • Put the text cursor in the address bar of http://arstechnica.com/ and hit Enter
      • Do not force refresh, as this soft clear the cache I believe
    • The Statistics page should show that very few items were logged following the main_frame event.
      • Since currently items are logged only for when items are not fetched from the cache.

    To confirm any fix works, check that all items on the page are logged, not just those items outside the cache.

  4. gorhill commented on Jan 18, 2014

    @gorhill
    OwnerAuthor

    Alright, I am losing track of, and forgetting earlier findings and now I am back to square one.

    webRequest.onResponseStarted/details.fromCache is no good, it works for objects pulled from the on-disk cache, not the in-memory cache. This bug here causes the following scenario to happen, which I should have documented first time I entered this bug:

    This is the bug. Still no solution.

  5. my-password-is-password commented on Jan 19, 2014

    @my-password-is-password
    Contributor

    What about using DOM Mutation Observers?

    Found this https://code.google.com/p/mutation-summary/

  6. ghost assigned on Jan 29, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions