mate-desktop / mate-settings-daemon

MATE settings daemon
https://mate-desktop.org
GNU General Public License v2.0
43 stars 48 forks source link

The PluginActivated DBus signal is no longer sent #418

Open tari01 opened 3 months ago

tari01 commented 3 months ago

Expected behaviour

When I subscribe to org.mate.SettingsDaemon + /org/mate/SettingsDaemon + PluginActivated via DBus, I expect to receive a notification for each activated plugin.

Actual behaviour

As of version 1.27.1, the daemon no longer sends the PluginActivated signal

Steps to reproduce the behaviour

Launch the mate-settings-daemon and create a signal watcher for PluginActivated. I have written a small Python test script to demonstrate this (works as expected on 1.27.0, does nothing on 1.28.0):

#!/usr/bin/env python3

from gi.repository import Gio
from gi.repository import GLib
import subprocess

pLoop = None

def onPluginActivated (pConnection, sSender, sPath, sInterface, sSignal, lParameters, pData):

    print (sInterface, sSignal, lParameters[0])

def onNameAppeared (pConnection, sName, sOwner):

    pConnection.signal_subscribe (None, "org.mate.SettingsDaemon", "PluginActivated", "/org/mate/SettingsDaemon", None, Gio.DBusSignalFlags.NONE, onPluginActivated, None)

if __name__ == '__main__':

    Gio.bus_watch_name (Gio.BusType.SESSION, "org.mate.SettingsDaemon", Gio.BusNameWatcherFlags.NONE, onNameAppeared, None)

    pSubprocess = subprocess.Popen (["/usr/lib/mate-settings-daemon/mate-settings-daemon", "--replace"])

    pLoop = GLib.MainLoop.new (None, True)
    pLoop.run ()

m-s-d-test.py.zip

MATE general version

1.28.0

Package version

1.28.0

Linux Distribution

Arch/Debian

tari01 commented 2 months ago

The cause of the issue seem to be the changes introduced in https://github.com/mate-desktop/mate-settings-daemon/commit/b99fca7671b9d30833e86838bd9b39ac36da1ea1 by @yetist. Even after going through the whole commit, I am not able to figure out why the daemon stopped sending signals...

lukefromdc commented 2 months ago

I don't have enough understanding of how dbus works to do anything with this one, so a fix will have to wait for one of the other team members.

joakim-tjernlund commented 2 days ago

The cause of the issue seem to be the changes introduced in b99fca7 by @yetist. Even after going through the whole commit, I am not able to figure out why the daemon stopped sending signals...

Can you revert that commit locally and see if that fixes the problem?

tari01 commented 2 days ago

The cause of the issue seem to be the changes introduced in b99fca7 by @yetist. Even after going through the whole commit, I am not able to figure out why the daemon stopped sending signals...

Can you revert that commit locally and see if that fixes the problem?

Yes. I've been using my own build of mate-settings-daemon with that commit reverted since I reported this issue. It works properly as before. There are some build changes that also need to to be reverted for the build to succeed.

joakim-tjernlund commented 2 days ago

The cause of the issue seem to be the changes introduced in b99fca7 by @yetist. Even after going through the whole commit, I am not able to figure out why the daemon stopped sending signals...

Can you revert that commit locally and see if that fixes the problem?

Yes. I've been using my own build of mate-settings-daemon with that commit reverted since I reported this issue. It works properly as before. There are some build changes that also need to to be reverted for the build to succeed.

Then perhaps do a MR with that revert, if new stuff breaks and no one fixes it, then it has to go.

lukefromdc commented 2 days ago

The worry is, will distros drop the old code? I don't have enough understanding of dbus to fix this and really can't maintain the whole DE solo, so this may take a while until other maintainers get back