GNOME Bugzilla – Bug 627369
Not receiving notifications after WriteMany
Last modified: 2010-08-23 14:13:22 UTC
My app uses g_settings_delay() / g_settings_apply() to write many changes at once. This properly corresponds to the WriteMany dbus method. However, another app (say simple 'gsettings monitor' command) listening to changes to the particular key is not receiving notify signals. This works properly if I remove the delay/apply combo. Looking at dbus, I see proper communication: > method call sender=:1.340 -> dest=ca.desrt.dconf serial=181 path=/ca/desrt/dconf/Writer/user; interface=ca.desrt.dconf.Writer; member=WriteMany > string "/desktop/gnome/background/" > array [ > struct { > string "color-shading-type" > array [ > variant string "solid" > ] > } > ... > struct { > string "secondary-color" > array [ > variant string "#ffffff" > ] > } > ] > signal sender=:1.287 -> dest=(null destination) serial=512 path=/; interface=ca.desrt.dconf.Writer; member=Notify > string "/desktop/gnome/background/" > array [ > string "color-shading-type" > ... > string "secondary-color" > ] > string "244:1.287" No signal arrives though. With single writes, the communication is like this: > method call sender=:1.277 -> dest=ca.desrt.dconf serial=38 path=/ca/desrt/dconf/Writer/user; interface=ca.desrt.dconf.Writer; member=Write > string "/desktop/gnome/background/draw-background" > array [ > variant boolean false > ] > signal sender=:1.287 -> dest=(null destination) serial=510 path=/ca/desrt/dconf/Writer/user; interface=ca.desrt.dconf.Writer; member=Notify > string "/desktop/gnome/background/draw-background" > array [ > ] > string "243:1.287" And we can see the incoming signal just fine. Debugging the gsettings backend in dconf code, it seems that the dconf_settings_backend_filter() callback is not called for Notify methods. I don't see any obvious reason for that though. dconf_settings_backend_subscribe() is always called with the '/desktop/gnome/background/' argument.
Oh I see the problem now - look at the 'path' argument for Notify method. And we're subscribing to > type='signal',interface='ca.desrt.dconf.Writer',path='/ca/desrt/dconf/Writer/user',arg0path='/desktop/gnome/background/'
path or arg0path?
(In reply to comment #2) > path or arg0path? path actually, arg0path looks sane.
oh. the problem is with the path that the service is sending on multiple-writes. Ok. Thanks for the report. This will be fixed in the next release.
should be fixed now