Inconsistency of the icon requests counter on Github #37
Comments
Ok we need to stick to uMatrix here, I am having a hard time making sense of what is reported. uBlock is rather different than uMatrix internally, and it is confusing me more if you report both -- which have different behavior -- as a single issue. I did see there was a problem with uMatrix not updating its badge. I think I got it fixed but I need to known exactly if this was the issue you reported, for now I can't figure exactly what you are reporting with uMatrix. Can you remove all references to uBlock so that I can clearly see what you are reporting with uMatrix? To save time, regarding 6): uBlock may block more than what appears in the request log, because it is not uncommon for the same net requests to be fired more than once. So each time a specific net request is blocked it is counted as +1, even though it will be reported once in the request log. That would be impractical to repeat the same URL many times in the request log. |
Sure thing, I have removed the references to uBlock on the issue. And about your reference to uBlock: |
I am also able to reproduce this issue on GitLab: When clicking on one of the top bar pages and going back with the mouse button. |
Ok, so at 5)-6) this is what I fixed: the badge wasn't updated. This was a case of the URL changing in the address bar, but no document load occurring. Re uBlock: it works quite differently than uMatrix. In uBlock, the stats are not reset when the URL in the address bar changes, they are reset when a new document is (re)loaded. Resetting uBlock stats whenever the URL changed was really annoying in some heavy cases of pages which change incrementally. Best example is Google Maps. Currently uMatrix is completely URL-based, so whenever the URL changes, a new internal data structure to hold matrix stats is created. This is annoying on site such as Google Maps. I think I may need to revise that to be more like uBlock, i.e. reusing internal data structure when the URL is updated without the main doc in the page being reloaded. |
Oops, the second fix hides the first fix. |
Steps:
Enter to any issues page on Github (for this reproduction, lets use uMatrix's issue page: https://github.com/gorhill/uMatrix/issues)
uMatrix is showing X amount of requests that the page made in the icon counter and the matrix cells itselves - lets call this number X. Take a note of this number.
Enter to any issue thread on this page (lets say right click on the "Support RTL languages" issue) - number of page requests (uMatrix) got changed on the icon counter and the matrix cells (as expected) - this number will be Y. Take a note of this number.
Head back to the issues page with the mouse back button.
Notice that icon counter of uMatrix hasn't changed - still showing the Y number.
Click on the matrix - See that the amount of requests in cells that is shown is the one that you had on the issue page "Support RTL languages", the previous page, not the current page. (it isn't the Y or some higher number as I believe it should be).
Note 1: After some time being idle on the page, the matrix icon counter can update and synchronize the correct amount of request.
Note 2: I think this is caused because of the caching mechanism that is used by Github (something like SPF on YouTube maybe), and uMatrix isn't really dealing with it properly.
The text was updated successfully, but these errors were encountered: