-
Notifications
You must be signed in to change notification settings - Fork 51
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
Does not work in chromium browsers, but works in gecko browsers #122
Comments
Thanks for the report, and sorry for the delay. Just to confirm: you've observed this plugin work in Firefox and Brave, but not in Chrome, right? |
Right. |
I have a similar problem. The extension works in Firefox, but does not work in Brave Browser. |
I had issues the other day with Brave in a mac pc. Turns out Brave does read the native messaging host of google chrome there as it does in windows. @justafreaky if you are on mac, try installing for chrome and see if that resolves your issue. |
Can anybody confirm that they're still observing these problems? We haven't received many other reports of Chromium-based browser breakage recently, so I suspect some of this is incorrect configurations (and if so, please help others by contributing to the wiki!) |
Here's how it doesn't play in mpv. |
Could you try placing the json manifest in Chrome's NativeMessagingHosts? Thorium may be reading that instead of its own. |
Doesn't work out of the box on Chromium Version 129.0.6622.0 (Developer Build) (64-bit). Some observations
here
the Manifest 2 deprecation notice
at
and
at browser-polyfill.js:792 (anonymous function)
|
Although this is probably not consequential for what's going on on Chromium-based browsers, this line https://github.com/woodruffw/ff2mpv/blob/master/ff2mpv.py#L52
has an issue in that the JSON is formatted, includes spaces. Those space characters are counted as strings in the 1048576 length of message from host to client. See mdn/webextensions-examples#510 and mdn/content#23451. The fix in Python is
|
That's chromium's behavior. Only way to keep the extension id is to publish it to the store. If you install it from the store, it should use that extension id but if you load it as an unpacked extension, it will change every time and you'll need to manually update the json manifest. Latest stable chrome is 127 and I can see the deprecation warning but ff2mpv still works there. Are you unable to install from the store in chrome 129?
It is almost done: #70 I understood that firefox didn't have support for service workers under MV3 yet, so the PR hasn't been merged. I haven't kept up with the deadlines for MV2 deprecation, so not sure when the extension will stop working. |
Agreed with everything @DanSM-5 said -- we don't currently support versions of Chrome/Chromium outside of stable channels (because of things like the MV2 -> MV3 transition). This could be documented better; you can help us out by putting a note on the wiki. Separately: @guest271314, would you be interested in sending a PR for that change? I don't think we're anywhere close to the 1MB message limit in this extension, but minimizing anyways doesn't seem like a bad idea. |
@woodruffw Sure. I would suggest updating your code to use Manifest 3. And use The bug is real here. At some point soon you're going to need to update this. If all the extension does is accept a URL and send that to |
Frankly, I don't install extensions from Chrome Web Store or Firefox's equivalent. I only load unpacked extensions that I write or from sources on GitHub where I can read the source code. I was just conveying that I would update the README/instructions to include the fact the dynamically generated extension ID needs to be updated manulally, or programmatically, if you want. E.g., https://github.com/guest271314/NativeMessagingHosts?tab=readme-ov-file#installation-and-usage
Technically that should only need to be done once, as the extension ID will not change once generated and you use the same extension code, or update the code. I have extensions I wrote I have used for years where the extension ID doesn't change. |
It now works both and chrome and brave, but not on thorium 124.0.6367.218. |
#70 will do this. If more people want to demo-run the changes in that PR and confirm that they work for them, then I'll happily merge them and make a release that uses MV3 instead.
Please feel free to contribute this to the wiki -- 99% of users are loading directly from AMO or the Chrome Store, so IMO putting it in the README is likely to confuse those users. But a dedicated section on the troubleshooting page is probably a good fit for it. |
For unpacked extension installed from GitHub repository we still have to set the generated extension ID. Not a big deal. Makes sure people in the field have to actuall do something other than press go to start using Native Messaging. Requires some human action.
|
In
and
then we're just left with
|
I know why this one is happening. When the background script starts there is no registered context menu with id browser.contextMenus.remove('ff2mpv'); Maybe using |
This doesn't change anything
|
This works
I get to the message from the Native Messaging host,
|
I can very the Python script works, until I build
|
Got it working with a local file, just to make just
|
By works I mean launches |
I've created a PR for the issue with |
I can't open videos in thorium browser using ff2mpv. I tried to use rust, ruby implementations, but they both don't work. Because of it I think the problem is in the script.
Reproduction steps
Steps to reproduce the behavior:
Expected behavior
Ability to play video in thorium browser.
Platform information
Edit: Works in the Brave browser
The text was updated successfully, but these errors were encountered: