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

Discord causes uBlock Origin Context Menu to disappear #1646

Open
4 of 8 tasks
Nicholas-Steel opened this issue Jul 1, 2021 · 10 comments
Open
4 of 8 tasks

Discord causes uBlock Origin Context Menu to disappear #1646

Nicholas-Steel opened this issue Jul 1, 2021 · 10 comments
Labels
unable to reproduce cannot reproduce the issue

Comments

@Nicholas-Steel
Copy link

Nicholas-Steel commented Jul 1, 2021

Prerequisites

  • I verified that this is not a filter issue
  • This is not a support issue or a question
  • I performed a cursory search of the issue tracker to avoid opening a duplicate issue
    • Your issue may already be reported
  • The issue is not present after wholly disabling uBlock Origin ("uBO") in the browser
    • If the issue is still present after wholly disabling uBO in the browser, then the issue is unrelated to uBO
  • I tried to reproduce the issue when...
    • uBO is the only extension
    • uBO with default lists/settings
    • using a new, unmodified browser profile
  • I checked the documentation to understand that the issue I report is not a normal behavior

Description

Context Menu item disappears a couple seconds after opening a website/navigating between tabs if Discord is loaded in any tab in any instance of Firefox.

All websites, but since a specific one is required...
www.cracked.com

[A specific URL is MANDATORY for issue happening on a web page, even if it happens "everywhere"]

Steps to Reproduce

  1. Load Discord in a tab (www.discord.com). May need to join a chat server, so here's a invite link to one https://discord.gg/ootrandomizer (N64 Ocarina of Time Randomizer project).
  2. Configure uBlock to be disabled/powered off for Discord.
  3. Open another tab and visit a website of your choosing.
  4. Right-click a couple times anywhere on the page that will spawn a browser context menu.

Expected behavior:

Context Menu item to appear when appropriate (essentially always appear).

Actual behavior:

For the first few seconds uBlock will appear in the right-click context menu, then it will stop appearing in the context menu. Closing the Discord tab resolves the issue immediately.

Demonstration:
https://youtu.be/RVxdMSDh000 (Discord is present in a tab in the other Firefox window)
https://youtu.be/f3UOAwjPLec

Your environment

  • uBlock Origin version: v1.36.0 through to 1.38.6
  • Browser Name and version: Firefox 88.0.1 and 89.0.2, 90.0.2 and 93.
  • Operating System and version: Windows 10 pro 21H1
  • Not a clean profile.
  • As seen in one of the videos it was demonstrated with all other add-ons disabled.
@Nicholas-Steel
Copy link
Author

Nicholas-Steel commented Jul 1, 2021

Potentially related issue: #151

@uBlock-user uBlock-user added the something to address something to address label Jul 10, 2021
@Nicholas-Steel
Copy link
Author

Also happens in Firefox 89.0.2

@mparchm
Copy link

mparchm commented Aug 16, 2021

Potentially related issue: #151

404

@Nicholas-Steel
Copy link
Author

Nicholas-Steel commented Aug 17, 2021

Potentially related issue: #151

404

Weird, I guess that issue got deleted? In any case the issue I reported persists in v90.0.2

Also I can't tick "I checked the documentation to understand that the issue I report is not a normal behavior" without it it self remaining unticked while other stuff gets ticked.

@gorhill gorhill added the unable to reproduce cannot reproduce the issue label Aug 17, 2021
@gorhill
Copy link
Member

gorhill commented Aug 17, 2021

I can't reproduce. It seems you have customized Firefox, please try in a new profile with no customization and uBO as the only extension.

@uBlock-user uBlock-user removed the something to address something to address label Aug 17, 2021
@Quotatron3000
Copy link

I think I can help expand on this issue as I can confirm I'm also encountering it.

If uBlock Origin is disabled in Discord, but no other websites, and Discord is open and logged in, after a few seconds (keep re-right clicking) of opening the context menu on another site in another tab in the same browser instance, the uBlock Origin context option disappears.

If uBlock Origin is re-enabled in Discord, or Discord is closed, normal context menu behaviour resumes. However this isn't a permanent solution as Discord is typically kept perpetually open and normally you don't want uBlock to interfere with Discord operations.

Affected browser: Firefox on Linux.

@Nicholas-Steel
Copy link
Author

Nicholas-Steel commented Oct 13, 2021

Huh, thank you for that extra information (I can confirm it's still an issue in Firefox 93). I've updated the reproduction steps in the original post.

@ghost
Copy link

ghost commented Oct 23, 2021

On any site, the essence is in a private window.
@gorhill https://www.reddit.com/r/uBlockOrigin/comments/qc78pu/block_element/ ?

@dessant
Copy link

dessant commented Dec 14, 2021

Hi @gorhill, we got to the root of a context menu bug when an Incognito window is opened in Chrome, and Discord was not needed for reproducing the issue.

The gist is that contextMenus.removeAll() removes menu items from all extension instances, but contextMenus.create() only creates menu items for the current instance, so when you open an Incognito window, the context menu item disappears from the regular window.

You can find more details about how it was fixed in my extension here: dessant/search-by-image#151 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
unable to reproduce cannot reproduce the issue
Projects
None yet
Development

No branches or pull requests

7 participants
@gorhill @dessant @Nicholas-Steel @uBlock-user @Quotatron3000 @mparchm and others