GNOME Bugzilla – Bug 781326
org.gnome.SettingsDaemon.MediaKeys is unowned
Last modified: 2017-04-26 10:05:36 UTC
This is a regression of 3.24 where gsd-media-keys does not own this bus name so applications error looking for a service file. As a slight extension to this dozens of applications, including GNOME ones like Totem and Evince, try to use the org.gnome.SettingsDaemon bus name which is now no longer owned. While technically incorrect it would be valuable to keep that working IMO.
Also it looks like this bus name was not owned in earlier releases too, so now applications must support both.
It seems that mediakeys are going though mpris now? So you remove a known, highly used interface and replace it with mpris? Massive regression, now not only can an app not depend on focus detection to grab and release the mediakeys as to play nice with other open players, but it can't disable mediakeys without also disabling another COMPLETELY UNRELATED service. Good job out a you guys...
(In reply to Jason Gray from comment #2) > It seems that mediakeys are going though mpris now? So you remove a known, > highly used interface and replace it with mpris? Massive regression, now not > only can an app not depend on focus detection to grab and release the > mediakeys as to play nice with other open players, but it can't disable > mediakeys without also disabling another COMPLETELY UNRELATED service. Good > job out a you guys... Aside from you having trouble reading bugs or code properly, attributing malice to a code bug that you failed to test for the months that it was present, and making me reel about how I would reply to this insult to my work during my days off, what exactly did you hope to achieve with this comment? I'll re-add you to the bug when you've sent me apologies via e-mail.
Created attachment 350203 [details] [review] media-keys: Fix mmkeys D-Bus API to match API docs Bizarrely, since 2011, gnome-settings-daemon was documented as using org.gnome.SettingsDaemon.MediaKeys D-Bus name, but everybody ended up using the org.gnome.SettingsDaemon owned by the daemon instead, and never reported the discrepancy. This fixes the code to match the 6-year old API as documented by owning the org.gnome.SettingsDaemon.MediaKeys D-Bus name. This patch will need to be backported as far as reasonably possible by distributions, and all users of the API changed. This would obviously have been easier if the problem was reported when detected, committer of this fix included...
Review of attachment 350203 [details] [review]: with that fixed, seem fine ::: plugins/media-keys/gsd-media-keys-manager.c @@ +2880,3 @@ g_debug ("Starting mpris controller"); manager->priv->mpris_controller = mpris_controller_new (); + manager->priv->mmkeys_name_id = g_bus_own_name (G_BUS_TYPE_SESSION, Since we register the API in on_bus_gotten() we should also claim the name there to avoid the case where we "lose" the race and have a window when we own the name but haven't exported the API yet.
Created attachment 350298 [details] [review] media-keys: Fix mmkeys D-Bus API to match API docs Bizarrely, since 2011, gnome-settings-daemon was documented as using org.gnome.SettingsDaemon.MediaKeys D-Bus name, but everybody ended up using the org.gnome.SettingsDaemon owned by the daemon instead, and never reported the discrepancy. This fixes the code to match the 6-year old API as documented by owning the org.gnome.SettingsDaemon.MediaKeys as well as the org.gnome.SettingsDaemon D-Bus name to give 3rd-party users time to adapt their code. The portion of this patch adding the org.gnome.SettingsDaemon.MediaKeys name owning will need to be backported as far as reasonably possible by distributions, and all users of the API changed before GNOME 3.26. This would obviously have been easier if the problem was reported when detected, committer of this fix included.
Review of attachment 350298 [details] [review]: lgtm
Created attachment 350299 [details] [review] media-keys: Fix mmkeys D-Bus API to match API docs Bizarrely, since 2011, gnome-settings-daemon was documented as using org.gnome.SettingsDaemon.MediaKeys D-Bus name, but everybody ended up using the org.gnome.SettingsDaemon owned by the daemon instead, and never reported the discrepancy. This fixes the code to match the 6-year old API as documented by owning the org.gnome.SettingsDaemon.MediaKeys as well as the org.gnome.SettingsDaemon D-Bus name to give 3rd-party users time to adapt their code. The portion of this patch adding the org.gnome.SettingsDaemon.MediaKeys name owning will need to be backported as far as reasonably possible by distributions, and all users of the API changed before GNOME 3.26. This would obviously have been easier if the problem was reported when detected, committer of this fix included.
Attachment 350299 [details] pushed as 42f75ed - media-keys: Fix mmkeys D-Bus API to match API docs Pushed to gnome-3-24. Similar patches will also be committed for gnome-3-22 and master, without the "org.gnome.SettingsDaemon" owning though.
E-mails have been sent to distributor-list@ and desktop-devel-list@, please pass it on.