[Python-modules-team] Bug#867794: python3-pyqt5: App tray icon won't show if show() before systray is available
Jérôme
jerome at jolimont.fr
Sun Jul 9 14:54:58 UTC 2017
Package: python3-pyqt5
Version: 5.7+dfsg-5
Severity: normal
Dear Maintainer,
my app uses a QSystemTrayIcon. When run manually, it works fine. When
run on startup, the icon often (if not always) does not show up,
although the program is running (appears in top).
It seems related to those issues:
https://stackoverflow.com/questions/5290611/
https://stackoverflow.com/questions/18213775/
People suggest this happens because the application is started before the
system tray is available. However, Qt docs state that:
http://doc.qt.io/qt-5/qsystemtrayicon.html
"If the system tray is unavailable when a system tray icon is constructed,
but becomes available later, QSystemTrayIcon will automatically add an entry
for the application in the system tray if the icon is visible."
I did check that by removing the system tray applet and it does not seem
to work as expected.
Systray available
Start app -> icon shows up
Remove systray
Add systray -> icon shows up
Alright. However:
Systray available
Remove systray
Start app
Add systray -> icon does not show up
Not what I'd expect from the docs.
I'm using Mate as a DE.
I recently moved to Stretch and this started to happen. I don't think it ever
occured on Jessie, although it could be because the starting order was
different and for some reason the systray was always available when the app
would start.
This occured on PyQt4. I moved to PyQt5 and it is still an issue.
I don't think it is a Mate issue.
I don't think I'm using QSystemTrayIcon the wrong way. In case it helps,
here is the code:
https://github.com/lafrech/gbirthday/blob/pyQt5_python3_port/src/gbirthday/statusicon.py
I can't tell whether this is a Qt or a PyQt issue, so I'm reporting against
PyQt as this is my entry point.
Please ask for more information if needed. Or tell me on which door to
knock if this is not the right place.
Thanks.
Jérôme
-- System Information:
Debian Release: 9.0
APT prefers stable
APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Kernel: Linux 4.9.0-3-amd64 (SMP w/4 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages python3-pyqt5 depends on:
ii libc6 2.24-11+deb9u1
ii libgcc1 1:6.3.0-18
ii libpython3.5 3.5.3-1
ii libqt5core5a [qtbase-abi-5-7-1] 5.7.1+dfsg-3+b1
ii libqt5dbus5 5.7.1+dfsg-3+b1
ii libqt5designer5 5.7.1-1
ii libqt5gui5 5.7.1+dfsg-3+b1
ii libqt5help5 5.7.1-1
ii libqt5network5 5.7.1+dfsg-3+b1
ii libqt5printsupport5 5.7.1+dfsg-3+b1
ii libqt5test5 5.7.1+dfsg-3+b1
ii libqt5widgets5 5.7.1+dfsg-3+b1
ii libqt5xml5 5.7.1+dfsg-3+b1
ii libstdc++6 6.3.0-18
ii python3 3.5.3-1
ii python3-sip [sip-py3api-11.3] 4.18.1+dfsg-2
python3-pyqt5 recommends no packages.
Versions of packages python3-pyqt5 suggests:
pn python3-pyqt5-dbg <none>
-- no debconf information
More information about the Python-modules-team
mailing list