Xfce Forum

Sub domains
 

You are not logged in.

#1 2021-12-29 00:20:24

bplo
Member
Registered: 2021-12-29
Posts: 6

xfce4-panel does not register StatusNotifier* services on dbus

I ran into this issue on Void Linux, using xfce4-panel version 4.16.3.

If I understand correctly, the Status Tray (systray) plugin of xfce4-panel should register org.kde.StatusNotifierHost and org.kde.StatusNotifierWatcher services on dbus. But, with the plugin added to my panel, I don't see those services appearing in the `d-feet` dbus debugging tool.

Background: one application I start (iwgtk) should appear in the systray, but it does not. Debugging that issue led me to the seemingly missing DBus services above. Context is here: https://github.com/J-Lentz/iwgtk/issues/21.

Questions:

1. Is it correct that those services should be started by the Status Tray Plugin?
2. Any ideas what could cause them not to be started on my system?

Thanks a lot for your help!

Offline

#2 2021-12-29 01:32:27

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,503

Re: xfce4-panel does not register StatusNotifier* services on dbus

bplo wrote:

I ran into this issue on Void Linux, using xfce4-panel version 4.16.3.

Testing this on my Arch install.

If I understand correctly, the Status Tray (systray) plugin of xfce4-panel should register org.kde.StatusNotifierHost and org.kde.StatusNotifierWatcher services on dbus.  But, with the plugin added to my panel, I don't see those services appearing in the `d-feet` dbus debugging tool.

I believe it just registers org.kde.StatusNotifierWatcher. I see it in my d-feet tool in the session bus. Also:

dbus-monitor 'type=signal',sender='org.kde.StatusNotifierWatcher'

...returns a live running interface.

Background: one application I start (iwgtk) should appear in the systray, but it does not. Debugging that issue led me to the seemingly missing DBus services above. Context is here: https://github.com/J-Lentz/iwgtk/issues/21.

Questions:

1. Is it correct that those services should be started by the Status Tray Plugin?
2. Any ideas what could cause them not to be started on my system?

Thanks a lot for your help!

Try the Xfce statusnotifier.py test script. This should display an icon in the status tray plugin. Also, with the above dbus-monitor command, I get:

signal time=1640741380.740664 sender=:1.1203 -> destination=(null destination) serial=877 path=/StatusNotifierWatcher; interface=org.kde.StatusNotifierWatcher; member=StatusNotifierItemRegistered
   string ":1.1248/org/ayatana/NotificationItem/xfce_sample_statusicon"

Does this sample work for you?

Offline

#3 2021-12-29 01:49:52

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,503

Re: xfce4-panel does not register StatusNotifier* services on dbus

Can you also post back the panel debug output:

xfce4-panel -q && PANEL_DEBUG=1 xfce4-panel

...then start iwgtk and see if there are any messages displayed.

And do you have libdbusmenu-gtk3  & libindicator-gtk3 installed?

Offline

#4 2021-12-30 08:39:59

bplo
Member
Registered: 2021-12-29
Posts: 6

Re: xfce4-panel does not register StatusNotifier* services on dbus

Thanks for the help so far!

I did not have those libraries installed, but now I do. They were installed as dependencies when I installed libappindicator-devel in order to get the statusnotifier.py test script working.

When I run the test script, the XFCE icon appears in the status tray. However, I do not see any output in the dbus-monitor command. Nor do I see the   org.kde.StatusNotifierWatcher or even an org.kde.StatusNotifierItem in d-feet's Session bus view.

When I run iwgtk I still get no icon in the tray. I do not see output in the dbus-monitor, nor in the xfce4-panel debug output. However, I do see its org.kde.StatusNotifierItem in d-feet's Session bus view...

This is weird. It appears I have 2 dbus sessions running under my user, not sure if this is WAI:

$ ps aux | grep dbus
root      1135  0.0  0.0   2200   768 ?        Ss   Dec29   0:00 runsv dbus
dbus      1136  0.0  0.0   3732  2952 ?        S    Dec29   0:01 dbus-daemon --system --nofork --nopidfile
bas      10488  0.0  0.0   4428   256 ?        S    09:10   0:00 /usr/bin/dbus-launch --sh-syntax --exit-with-session xfce4-session
bas      10489  0.0  0.0   3680  2200 ?        Ss   09:10   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 5 --print-address 7 --session
bas      10502  0.0  0.0   3388  2732 ?        S    09:10   0:00 /usr/bin/dbus-daemon --config-file=/usr/share/defaults/at-spi2/accessibility.conf --nofork --print-address 3
bas      11428  0.0  0.0   2796   952 pts/1    S+   09:27   0:00 dbus-monitor type=signal,sender=org.kde.StatusNotifierWatcher
bas      11594  0.0  0.0   7960  2372 pts/0    S+   09:34   0:00 grep dbus

Here's the full debug output of xfce4-panel:

$ xfce4-panel -q && PANEL_DEBUG=1 xfce4-panel
xfce4-panel(main): version 4.16.3 on gtk+ 3.24.30 (3.24.29), glib 2.70.2 (2.68.2)
xfce4-panel(module-factory): reading /usr/share/xfce4/panel/plugins
xfce4-panel(application): found window manager after 1 tries
xfce4-panel(base-window): 0x55fa319b4380: rgba visual=0x55fa3195a190, compositing=false
xfce4-panel(base-window): 0x55fa319b4380: rgba visual=0x55fa3195a190, compositing=false
xfce4-panel(display-layout): 0x55fa319b4380: display=:0.0{comp=true}, screen-0[0x55fa3194e020]=[2560,1440] (eDP1=[0,0;2560,1440])
xfce4-panel(positioning): 0x55fa319b4380: screen=0x55fa3194e020, monitors=1, output-name=(null), span-monitors=false, base=0,0
xfce4-panel(positioning): 0x55fa319b4380: working-area: screen=0x55fa3194e020, x=0, y=0, w=2560, h=1440
xfce4-panel(struts): 0x55fa319b4380: top=33, start_x=0, end_x=2559
xfce4-panel(module): new item (type=object-type, name=applicationsmenu, id=1)
xfce4-panel(module): new item (type=object-type, name=launcher, id=19)
xfce4-panel(module): new item (type=object-type, name=launcher, id=17)
xfce4-panel(module): new item (type=object-type, name=launcher, id=18)
xfce4-panel(module): new item (type=object-type, name=tasklist, id=2)
xfce4-panel(module): new item (type=object-type, name=separator, id=3)
xfce4-panel(module): new item (type=object-type, name=pager, id=4)
xfce4-panel(module): new item (type=object-type, name=separator, id=5)
xfce4-panel(external): register dbus path /org/xfce/Panel/Wrapper/7
xfce4-panel(module): new item (type=external-wrapper, name=pulseaudio, id=7)
xfce4-panel(external): pulseaudio-7: child spawned; pid=11522, argc=7
xfce4-panel(external): register dbus path /org/xfce/Panel/Wrapper/9
xfce4-panel(module): new item (type=external-wrapper, name=power-manager-plugin, id=9)
xfce4-panel(external): power-manager-plugin-9: child spawned; pid=11523, argc=7
xfce4-panel(external): register dbus path /org/xfce/Panel/Wrapper/10
xfce4-panel(module): new item (type=external-wrapper, name=notification-plugin, id=10)
xfce4-panel(external): notification-plugin-10: child spawned; pid=11524, argc=7
xfce4-panel(module): new item (type=object-type, name=separator, id=11)
xfce4-panel(module): new item (type=object-type, name=clock, id=12)
xfce4-panel(module): new item (type=object-type, name=separator, id=13)
xfce4-panel(external): register dbus path /org/xfce/Panel/Wrapper/14
xfce4-panel(module): new item (type=external-wrapper, name=actions, id=14)
xfce4-panel(external): actions-14: child spawned; pid=11531, argc=7
xfce4-panel(external): register dbus path /org/xfce/Panel/Wrapper/6
xfce4-panel(module): new item (type=external-wrapper, name=systray, id=6)
xfce4-panel(external): systray-6: child spawned; pid=11532, argc=7
xfce4-panel(external): pulseaudio-7: child is embedded; 7 properties in queue
xfce4-panel(external): power-manager-plugin-9: child is embedded; 7 properties in queue
xfce4-panel(external): notification-plugin-10: child is embedded; 7 properties in queue
xfce4-panel(external): systray-6: child is embedded; 7 properties in queue

(wrapper-2.0:11524): GLib-GIO-CRITICAL **: 09:32:43.640: g_file_new_for_path: assertion 'path != NULL' failed

(wrapper-2.0:11524): GLib-GIO-CRITICAL **: 09:32:43.640: g_file_monitor_file: assertion 'G_IS_FILE (file)' failed

(wrapper-2.0:11524): GLib-GObject-WARNING **: 09:32:43.640: invalid (NULL) pointer instance

(wrapper-2.0:11524): GLib-GObject-CRITICAL **: 09:32:43.640: g_signal_connect_data: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed

(wrapper-2.0:11524): Gtk-WARNING **: 09:32:43.640: Attempting to add a widget with type GtkToggleButton to a container of type XfcePanelPlugin, but the widget is already inside a container of type XfcePanelPlugin, please remove the widget from its existing container first.
xfce4-panel(external): actions-14: child is embedded; 7 properties in queue
xfce4-panel(systray): rgba visual is 0x55b394e66d90
xfce4-panel(systray): registered manager on screen 0

(wrapper-2.0:11522): Gtk-WARNING **: 09:32:43.700: Negative content width -3 (allocation 1, extents 2x2) while allocating gadget (node button, owner PulseaudioButton)

(wrapper-2.0:11524): Gtk-WARNING **: 09:32:43.708: Negative content width -3 (allocation 1, extents 2x2) while allocating gadget (node button, owner GtkToggleButton)

(wrapper-2.0:11523): Gtk-WARNING **: 09:32:43.807: Negative content width -3 (allocation 1, extents 2x2) while allocating gadget (node button, owner PowerManagerButton)

Offline

#5 2021-12-30 09:15:06

bplo
Member
Registered: 2021-12-29
Posts: 6

Re: xfce4-panel does not register StatusNotifier* services on dbus

It appears I have 2 dbus sessions running under my user, not sure if this is WAI:

It is probably fine, the one with PID 10502 is not a session, just a local dbus daemon that is part of the at-spi-bus-launcher process.

Last edited by bplo (2021-12-30 09:15:26)

Offline

#6 2021-12-30 13:37:32

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,503

Re: xfce4-panel does not register StatusNotifier* services on dbus

Strange that the xfce test program works but not iwgtk.

How do you start your system? Display Manager or startx? Which display manager or what are the contents of your X start up (.xinitrc) file? I'm not that familiar with Void Linux, but have you set up dbus properly? This page seems to indicate that you need to run xfce4-session with dbus-run-session - you seem to be running it with dbus-launch.

Offline

#7 2021-12-30 21:28:35

bplo
Member
Registered: 2021-12-29
Posts: 6

Re: xfce4-panel does not register StatusNotifier* services on dbus

I use a Display Manager (lightdm), which runs the XFCE session by executing startxfce4. According to the page you refer to, that should do the right thing:

Most desktop environments, if launched through an adequate display manager, will launch a D-Bus session themselves.

Yeah, I used to execute i3wm using startx and was running dbus-run-session from my .xinitrc. To be sure, I moved that file out of the way, but it did not get executed anyway. Lightdm simple executes /etc/lightdm/Xsession which just loads /etc/profile and .Xresources, then executes startxfce4.

Offline

#8 2021-12-31 02:30:00

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,503

Re: xfce4-panel does not register StatusNotifier* services on dbus

So I installed void linux in a vm to have a closer look. First thing I noticed is that status notifier support doesn't appear to be built into xfce4-panel - meaning that if you go to the Status Tray plugin you don't get two separate sections. Here is what it looks like in Arch:
stp.png
(Note the "Status Notifiers" and "Systray Icons" toggles).

I don't know enough about void to try re-compiling xfce4-panel - it would be interesting to see the build logs but I can't find them. On Arch, libdbusmenu-gtk3 is required - so I'm thinking that maybe xfce4-panel needs to built with this package installed.

Offline

#9 2022-01-02 23:14:03

bplo
Member
Registered: 2021-12-29
Posts: 6

Re: xfce4-panel does not register StatusNotifier* services on dbus

Ah, thanks a lot for checking that in a VM. That explains.

I followed the Void instructions for package building and fixed the issue by simply adding a make-dependency on libdbusmenu-gtk3. I verified this works by running the panel and iwgtk. The pull request is here:
https://github.com/void-linux/void-packages/pull/34818

Offline

#10 2022-01-14 14:27:11

bplo
Member
Registered: 2021-12-29
Posts: 6

Re: xfce4-panel does not register StatusNotifier* services on dbus

The PR was merged. Should be fixed now. Thanks for the help!

Offline

#11 2022-01-14 18:21:42

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,503

Re: xfce4-panel does not register StatusNotifier* services on dbus

bplo wrote:

The PR was merged. Should be fixed now. Thanks for the help!

Thanks for the follow-up.

Offline

Board footer

Powered by FluxBB