yorkxin / copy-as-markdown

A browser extension to copy tabs and links as Markdown
MIT License
529 stars 81 forks source link

Firefox 106: Context Menu occationally disappear #109

Closed yorkxin closed 2 weeks ago

yorkxin commented 1 year ago

Summary

Context menu is sometimes not showing up in Firefox 106.

Not always reproducible.

Edit: seems to be related to non-persistent background page.

manuzhang commented 1 year ago

I'm seeing this issue now with Firefox 106.0.5. It always disappears.

yorkxin commented 1 year ago

@manuzhang thanks. I'm using Firefox too, but I can't tell under what situation it appears or disappears...

manuzhang commented 1 year ago

Disabling and re-enabling the extension gives me back one item in the context menu. However, there should be more?

image
yorkxin commented 1 year ago

@manuzhang thanks. I guess I know where the issue comes from (related: https://github.com/yorkxin/copy-as-markdown/issues/107)

Regarding to the list of context menus, it depends on the item that you clicked. On a link it only shows Copy Link. On an image it shows Copy Image and Copy Image + Link command. On other places on the web page, it shows Copy Current Tab.

manuzhang commented 1 year ago

so is this already fixed in latest version?

yorkxin commented 1 year ago

No, I think the issue still exists after #107 🥲 In fact I don't see context menu on my Firefox today.

jman-schief commented 1 year ago

If it helps I can reproduce this issue every time I update Firefox (I am on the beta channel so I receive updates quite often). After every update the context menu item disappears.

To workaround the issue I disable then enable again the extension, the context menu item is back.

yorkxin commented 1 year ago

Dear folks, do you still experience this issue?

jman-schief commented 1 year ago

Dear folks, do you still experience this issue?

@yorkxin I do (Firefox 111.0b8). As per my previous comment, I just work around it :)

manuzhang commented 1 year ago

The issue still exists in 110.0.1 and I need to re-enable the extension to work around as well.

yorkxin commented 1 year ago

Hi all, I've released a new version 2.8.3, and hopefully this time the issue gets resolved. Please let me know how it goes!

jman-schief commented 1 year ago

@yorkxin thanks for working on this issue. on my firefox 114 the extension now behaves in a different way:

As soon as I receive the next firefox update I can test what happens after updating the browser

EDIT: just updated to the latest firefox 114 beta and the context ment does not show up

manuzhang commented 1 year ago

@yorkxin Same for me on Firefox 113.0.1. Disabling and enabling the extension no longer works.

jman-schief commented 1 year ago

I didnt investigate very deep but I think the issue is that there is no API under chrome.runtime. to catch the event when an extension is enabled by the user. I only see the onInstalled event that is triggered when the extension is first installed.

I've tried triggering a browser.contextMenus.create on window.onload and the context menu appears also when the user enable/disable the extension but it's not exactly what we want :-)

I'm not sure if we can get away without custom code for chrome, firefox-mv2 and firefox-mv3 :man_shrugging:

azzamsa commented 1 year ago

Compared to other extension. It always warn me about "Permission needed to read and change data" Firefox indicate this with a blue dot.

image

azzamsa commented 1 year ago

I tried 113.0.2 but the context menu is still missing. I don't know why other context menu are there.

image

I have tried to use Brave because this extension works seamlessly in Brave. However, sometimes it needs a Google service extension. It is the reason I move back to Firefox.

I know it is an open-source project. It is not first-class paid ticket support. But I hope it will get resolved, as I use this extension a zillion times a day.

azzamsa commented 1 year ago

After couple of day. Maybe restart / other updates I did. Now I can use the context menu in 113.0.2 :tada:

image

Ganton commented 1 year ago

It also happens to me using Firefox 113.0.2, even after restarting it, and disabling and enabling Copy as Markdown...

manuzhang commented 1 year ago

The issue no longer exists in Firefox 114.0.2

redeyes2015 commented 1 year ago

For me, after re-installing the extension in Firefox 114.0.2, and clicking the extension icon in the menu bar, the item in context menu shows up properly.

manuzhang commented 1 year ago

This issue reappeared in 115.0.2 (64-bit)

jhermann commented 1 year ago

Works for me in FF 102 32bit ESR, and does not in FF 116 64bit, both under Windows 11.

Ganton commented 1 year ago

Works for me in FF 102 32bit ESR, and does not in FF 116 64bit, both under Windows 11.

Does not work for me in FF 116 64bit under Linux.

hesselmonk commented 10 months ago

Ironically this issue is fixed for me by downgrading the plugin to Version 2.7.1 using FireFox 119.0 (64-bit) on Windows

jman-schief commented 10 months ago

As a reminder for those subscribed to this issue: I did a little investigation (see comment). If anyone wants to take it further and maybe submit a patch, I think that would be great.

v-marinkov commented 8 months ago

I just installed it for the first time and I was never able to see the context menu in Firefox 121. Any ideas?

jman-schief commented 8 months ago

@v-marinkov to my knowledge, the only workaround is installing the previous version 2.7.1. After every update of Firefox the context menu will disappear: to have it back you'll have to disable and enable the extension

StefanBrand commented 8 months ago

I downgraded to version 2.7.1 and context menu immediately started to appear again.

yorkxin commented 5 months ago

Memo: this is a known issue in Firefox MV3. https://discourse.mozilla.org/t/strange-mv3-behaviour-browser-runtime-oninstalled-event-and-menus-create/111208/14

Some extensions such as Leechblock NG, use a 1 second polling to recreate menus.

yorkxin commented 5 months ago

Hi all, I've introduced a new version 2.9.1 as an attempt to resolve this issue. If the issue still exists, I will try to reimplement some code for the Firefox version. (For developers: Specifically, changing the extension's architecture from MV3 to MV2)

Please upgrade to 2.9.1 and see if the issue still exist. Thanks!

manuzhang commented 5 months ago

2.8.3 is working for me on Firefox 124.0.2 (64-bit)

yorkxin commented 3 weeks ago

Has anyone encounter this issue recently (since May 2024)?

manuzhang commented 3 weeks ago

I haven't seen this issue since my comment above ☝️

jman-schief commented 3 weeks ago

I've upgraded from 2.7.1 to 3.0.1 and the issue seems resolved :+1:

yorkxin commented 2 weeks ago

Thanks! I'll close this for now.