-
-
Notifications
You must be signed in to change notification settings - Fork 21
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
Chromium/Chrome 75 exposes a broken MPRIS interface. #10
Comments
On further investigation it seems that disabling the enable-media-session-service flag stops Chromium/Chrome from putting up the broken interface. So I don't think I will be blacklisting Chromium/Chrome after all. I think this is just a case of prematurely enabling a feature before it's fully baked. So my advice is to disable the enable-media-session-service flag until it actually works. |
That may be so for YouTube or PlayMusic, but the with the spotify PWA (https://open.spotify.com/), one gets good MPRIS support (play/pause/back/forward) with your extension. The gnome shell notification area, for some reason, does not show the controls... |
The logs show "JS ERROR: Exception in callback for signal: changed: TypeError: this._player.trackArtists.join is not a function" My guess would be that they are sending the artist metadata as a string and not an array of strings as it should be according to spec... My extension is quite a bit more forgiving of types when it comes to parsing the metadata: I tend to assume that all players are broken in at least one way or another, because with very few exceptions they are... |
Hmmm, I see. I guess there is no point trying to contact Spotify to fix this, right? It appears like they give zero feedback to Linux-related inquiries. |
It's not a Spotify bug. It's a Chrome bug. Spotify is not creating the MPRIS interface when you use their web player on Chrome, Chrome is. |
You can try to file a bug report with Chromium/Chrome. But I doubt anyone will listen. As I said it's a case of prematurely enabling a feature. They have to know it doesn't work I would think? |
Ah - ok. I could, but maybe they would be more interested in hearing from you, as a dev, regarding this? Or I could file in chromium and mention this thread? |
There intention (along with GNOME and other Linux desktop devs) is to use MPRIS for media key bindings. On the surface that may seem reasonable but it has one major flaw. There is no way in MPRIS to tell who to give the keys to in the event of more than one player. MPRIS lacks any sort of "focus" or "last user interaction time" properties. You'd need a platform/desktop agnostic way to tell who is the focused player and/or who was the last player the user interacted with to tell who to give the keys too. Adding the porps to the MPRIS spec is a possibility, but I don't trust players to implement them properly. I have the feeling that devs who choose to use MPRIS as media keys will be inundated with bug reports for players that they can't do anything about and the experience as a whole will degrade. |
This focus thing is a big flaw I experience all the time. Has it been reported somewhere? |
I mentioned it in a bug report for key binding back in 3.20 it was I think. I not so politely told them it was a dumb ass idea. (which got me locked out of the thread,lol!!!) They don't care. It's just there way of moving more functionality and responsibility out of GNOME Shell so that when someone else complains they can just say "That's not our bug". |
They'll just figure out some kind of sideband GLib app only way to work around it. What really needs to happen if it hasn't already is a desktop agnostic mediakeys binding DBus interface. |
Ok I'll try to look around and ask if something like that is in development, thanks. |
GNOME Shell sucks at keeping track of focused apps. Separate instances of an app are treated as the same app by default. That's why I wrote the AppWrapper class. Otherwise you run into edge cases like if you have 2 instances of VLC and you try to raise one of them. Who knows which one it will actually raise if you call |
@JasonLG1979 However, that MR has already gotten some pushback. ...From you. Oh. Never mind! 😉 |
It's not that I'm totally opposed to a "focused" prop I just think that it's a mistake and asking for trouble to leave it up to players to provide a timestamp. As I stated I think a Boolean is a better idea. The client should decide how they want to sort the players. As old as the MPRIS spec is most player implementations are still incomplete or broken sometimes in the most brain dead ways. Adding one more fairly critical thing for players to screw up is IMHO not a good idea. Not to mention that the time in the MR is in Epoch time (eww)... |
I'm trying to run electron with Does anybody have some documentation on the |
My bad it's An easy way to play with flags is to go to chrome://flags/ change the flag you want, restart Chrome and then go to chrome://version/ and see what the command line arg is. |
In my setup (Vivaldi 3.0 / Chromium 81.0.4044.142) it is actually I needed this to prevent the browser to grab the media keys (even if there is no player active) and make them not functional with Spotify. Hope can help. |
It seems that the |
Settings in the extension are a no go so there's no real way to make everyone happy. Some may want Chrome to show up in the extension so a blanket ban is also not ideal. The Chrome devs really should just fix their shit. |
I totally agree with you, Chrome devs should just fix this. Nonetheless, it's unrealistic that it will ever happen. |
To my knowledge config files are not really a thing for extensions. The conical way is to have a setting UI and associated gsettings. I'm not a fan at all of settings or a config file for what should be (and currently is) a very simple (in operation) extension. That's just a doorway for feature creep or at least endless feature requests. I consider this extension to be feature complete. |
There's another flag that still is present in Chrome 101,
So, it may well be that they've gotten the message that MPRIS is not the way to go with this, and are planning to let media players directly grab media controls (along with any other keystrokes they want to treat specially)... but only when fullscreened. Which seems reasonable, and handily ducks the focus issue entirely. |
As the title says Chromium/Chrome 75 exposes a broken interface. The only thing that currently works is metadata (limited to artist and title) and playback status. All other properties and methods seem to be nonfunctional. (rendering the controls in the extension also nonfunctional) On top of that once the interface shows up it never goes away even after navigating away from a supported sites like YouTube or PlayMusic.
Until it actually works I think the best thing to do is blacklist Chromium/Chrome for now.
The text was updated successfully, but these errors were encountered: