gorhill / uMatrix

uMatrix: Point and click matrix to filter net requests according to source, destination and type
GNU General Public License v3.0
4.56k stars 470 forks source link

Revert/Commit button hangup #971

Closed uBlock-user closed 6 years ago

uBlock-user commented 6 years ago

Steps to Reproduce

1) Browse to https://www2.fmovies.se/

2) Open the popup UI and block script from domain cdnjs.cloudflare.com, should look like this - https://i.gyazo.com/e15c7dcf4273984e507157d0a8c80f6e.png

3) Do a cache free reload of the page by pressing Ctrl + R or Ctrl + Refresh button near the address bar.

4) Now open Dashboard and browse to My rules, click on the Revert button, observe that it won't grey out and nothing happens, button appears stuck, now click on the Commit button, observe the same behavior there as well.

Browser Info

Chromium 67/ uMatrix 1.3.3.9 Win 10 x64

uBlock-user commented 6 years ago

@gorhill made a video to show it looks like

https://i.gyazo.com/481af3f199ee9e42f9ad0975f80b3cd9.mp4

korpjack commented 6 years ago

I could be wrong, but it looks like both sides of the rules (perma and temp) are the same. Are they? If they are nothing would change.

uBlock-user commented 6 years ago

Not completely same, when I click the revert button the new rules in temp get deleted, but the button remains active, and so does the commit button. The buttons are getting stuck, that's the issue.

gorhill commented 6 years ago

Not found in issue report:

uBlock-user commented 6 years ago

Whether this occurs in stable release of the browser

I don't use stable builds of Chromium, so can't test.

Whether errors are reported in page and extension console

@gorhill

uBlock-user commented 6 years ago

Were you able to reproduce ?

talklittle commented 6 years ago

I had this problem when Firefox (59.0.1) auto-updated from uMatrix 1.3.2 to 1.3.4.

Solved by exporting rules to a file, editing and deleting all rules, then re-importing the rules from the file.

Maybe some rule formatting difference going from 1.3.2 to 1.3.4, e.g. trailing whitespace?

uBlock-user commented 6 years ago

Solved by exporting rules to a file, editing and deleting all rules, then re-importing the rules from the file.

If it works for you, then that's a workround, NOT a solution when the bug exists in the extension itself. I could fix it too by rebooting chrome that way.

korpjack commented 6 years ago

I am using Firefox (no issues), but I took a look at the source and the mechanism that toggles those buttons' visibility is done this way: uDom('#diff').toggleClass('dirty', response.temporaryRules !== response.permanentRules);
The toggleClass adds or removes the dirty class from the container div. To debug this in chrome, one could check if this class name gets added/removed with each click by using inspect-element, and proceed from there.

uBlock-user commented 6 years ago

Well, I guess you were unable to reproduce ultimately, so I will close it.

-- Fixed with 1.3.5.0 dev build.