Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blacklist fails to match against a pattern I added #542

Open
StentMan opened this issue Sep 21, 2020 · 10 comments
Open

blacklist fails to match against a pattern I added #542

StentMan opened this issue Sep 21, 2020 · 10 comments
Labels

Comments

@StentMan
Copy link

Describe your matter in detail

This site uses it's own set or right-click gestures which conflict with Gesturefy. Gesturefy overrides the site's features. Yes, I use right-click as the activation button.
How to reproduce:

  1. Add the following blacklist pattern: ://www.chess.com/game/live/
  2. Register a free account at www.chess.com and start playing a 5 minute game. The URL on the actual game page should look something like this: https://www.chess.com/game/live/5477498819. If it doesn't, then you're redirected to the old game page who's blacklist pattern (://www.chess.com/live?) works just fine.
  3. Try doing gestures - for me, at least, the gestures work so the blacklist isn't working as expected. Maybe this only happens on 2nd or 3rd game? not sure. When the game is done just click the new 5 min game button on the right.

Fun fact: if I refresh the game page gestures no longer works.

Screenshots or further assistance

Your System

  • Operating system: Windows 10
  • Firefox version: 80.0.1
  • Gesturefy version: 3.0.7
@Robbendebiene
Copy link
Owner

You should use this blacklist entry: *://www.chess.com/game/live/*

@StentMan
Copy link
Author

StentMan commented Sep 22, 2020

Yes, that's the entry I used. Sorry for the mixup, I don't know why the asterix characters were removed from my post. probably should've escaped them, somehow. When I hit edit on the OP they're still there. You can see for yourself when you quote reply they're being replaced by underscores. Odd (or not).
Anyway, unfortunately, I, seemingly, used the correct blacklist entry and it doesn't work. That's, in a nutshell, the bug report. As I wrote, this site is somewhat unusual, as it uses its own set of right-click gestures: a simple right-click to cancel pre-moves, right-click drag to draw arrows on the chess board.

@Robbendebiene
Copy link
Owner

Yeah I see. anything surrounded by asterix is transformed into italic style by githubs markdown.

Okay I haven't created an account, but if I just visit https://www.chess.com/game/live/5477498819 with the blacklist entry applied gestures are disabled correctly for me.

As I wrote, this site is somewhat unusual, as it uses its own set of right-click gestures: a simple right-click to cancel pre-moves, right-click drag to draw arrows on the chess board.

I'm also able to do this.

Fun fact: if I refresh the game page gestures no longer works.

This lets me suspect that when you start playing a new game the website does not change entirely (it basically only changes and loads some new content, but not an entire new page). After that it probably adjusts the URL. In this case Gesturefy would miss that you are on a new URL. Can you confirm this? If this would be the problem I should be able to fix this.

@StentMan
Copy link
Author

This lets me suspect that when you start playing a new game the website does not change entirely (it basically only changes and loads some new content, but not an entire new page). After that it probably adjusts the URL. In this case Gesturefy would miss that you are on a new URL. Can you confirm this? If this would be the problem I should be able to fix this.

Confirm this how? I'm not sure what kind of actions/observations you'd like me to perform in order to confirm that?
And thank you for looking into this.

@Robbendebiene
Copy link
Owner

Can you send me a short screen recording of the steps you've described above, so I can see when the URL changes in the address bar? You basically can also observe this your own if you look carefully at the browsers reloading symbol. If it does not change shortly to an X symbol after you've started a new game (in other words the browser changed the URL to https://www.chess.com/game/live/XXX) then my assumption is correct.

@StentMan
Copy link
Author

StentMan commented Sep 22, 2020

Sure, I can do that.
Edit: I'm uploading the vid capture, will PM you the link in a sec.
Edit2: haha, no PM-ing. it's not a "proper" forum. Here's the link: https://app.box.com/s/m0wmyqqwjcej0pxiu1sdqhibkib44fys
Not that it matters, but I won that game

Thanks again for looking into it.

@Robbendebiene
Copy link
Owner

Thanks for the video! Exactly as I've supposed.
I should be able to fix this. In the mean time you can only use a disable button (alt, ctrl etc.) as a workaround.

Edit2: haha, no PM-ing. it's not a "proper" forum. Here's the link: https://app.box.com/s/m0wmyqqwjcej0pxiu1sdqhibkib44fys

Yep, sadly this is not possible on Github. (You can now remove the video or link if you want to)

Not that it matters, but I won that game

Not that it matters, but only 5 minutes for a chess round would be way too hectic for me :D

@StentMan
Copy link
Author

StentMan commented Sep 23, 2020

I won't prioritize this bug if I were you. this is a new game page chess.com is rolling out or, maybe, it's a work in progress. I just played today and the game redirected me to the old game page who's url looks something like this: https://www.chess.com/live?#g=5486375113 and for that page the blacklist rule *://www.chess.com/live?* works just fine.
This has happened in the past, they went back and forth with this new page and back 2-3 times already.

@StentMan
Copy link
Author

StentMan commented Nov 4, 2020

Did you fix it? or, maybe, they made some changes to the page? Either way, after a long while I played some chess, again on chess.com and the blacklist pattern worked.
You can mark this as fixed (or not a bug?).

Thanks for looking into this.

@StentMan StentMan closed this as completed Nov 4, 2020
@Robbendebiene
Copy link
Owner

Thanks for the update. I implemented the fix, but it's not shipped yet. They probably changed something on their website.
I'm reopening this ticket as a reminder and I'll close it again when the fix is shipped.

@Robbendebiene Robbendebiene reopened this Nov 4, 2020
Robbendebiene added a commit that referenced this issue Jun 5, 2022
Firefox will provide global user controls for site access per add-on.

See:
-  https://bugzilla.mozilla.org/show_bug.cgi?id=1497075
- https://bugzilla.mozilla.org/show_bug.cgi?id=1711787

Removing this option from Gesturefy reduces the amount of code that needs to be maintained. It's also more performant to exclude the entire content script from running than doing content script side checks.
Last but not least exclusions have always been a power feature that never really fit into Gesturefy from a design/UI standpoint.
Also resolves #542
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants