After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 683829 - Notifications with big data blobs (icon_data for instance) will freeze the Shell for a few seconds
Notifications with big data blobs (icon_data for instance) will freeze the Sh...
Status: RESOLVED OBSOLETE
Product: gnome-shell
Classification: Core
Component: message-tray
3.4.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2012-09-11 22:57 UTC by Raphael Hertzog
Modified: 2021-07-05 14:13 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Raphael Hertzog 2012-09-11 22:57:44 UTC
The Smuxi IRC client (version 0.8.10) sends notifications for IRC highlights with an embedded picture as blob (icon_data parameter of the spec):

Here's the output of dbus-monitor to explain what I mean:

method call sender=:1.105 -> dest=org.freedesktop.Notifications serial=45 path=/org/freedeskto
p/Notifications; interface=org.freedesktop.Notifications; member=Notify
   string "smuxi-frontend-gnome"
   uint32 0
   string ""
   string "#smuxi"
   string "<meebey> buxy: highlight"
   array [
      string "show"
      string "Afficher"
   ]
   array [
      dict entry(
         string "category"
         variant             string "im.received"
      )
      dict entry(
         string "icon_data"
         variant             struct {
               int32 256
               int32 256
               int32 1024
               boolean true
               int32 8
               int32 4
               array of bytes [
                  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[... here I'm snipping screens and screens of binary data ...]
                  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
                  00 00 00 00
               ]
            }
      )
   ]
   int32 -1

When the shell receives such a notification, it just freezes 2-3 seconds before displaying it. For instance, any window/desktop change happens with 2-3 seconds lag. Strangely even my typing in gnome-terminal is blocked in that period.

One can argue that smuxi should not send that binary blob in the message itself but the spec allows it and IMO the Shell should support this better, maybe it needs to be modified to read those data asynchronously ? (I have no idea of the current implementation, I did not check)
Comment 1 Jasper St. Pierre (not reading bugmail) 2012-09-12 00:46:42 UTC
My guess is that we copy the data twice (one towards JS, one back towards C) more than we need to. That's predicated on us getting a raw GVariant that we can pass to the C code, and that will require the GDBus rework of 3.8.
Comment 2 Mirco Bauer 2012-09-23 08:08:29 UTC
Smuxi passes big icons as per Ubuntu's Notify-OSD Guidelines [0]. In this particular case it is a 256x256 pixel PNG file [1] which is 26K in file size. This "big" icon was never an issue before with any tested notification daemon implementation (at that time that was: notify-osd 0.9.23, notification-daemon 0.5.0, and xfce4-notifyd 0.1.0). Also the notification specification 0.9 only allowed to show icons by passing the icon_data. With the 1.1 and 1.2 spec icon-path/icon_path can be used instead which would avoid this issue. Also a reduced version like 128x128 or smaller (if gnome-shell is the provider) could enhance this situation.

[0]: https://wiki.ubuntu.com/NotificationDevelopmentGuidelines#If_a_notification.2BIBk-s_icon_looks_blurry_or_jagged
[1]: http://git.qnetp.net/?p=smuxi.git;a=blob;f=images/group-chat_256x256.png;h=361b6d156275b8eaa5e70c372fe23764971e1f7e;hb=HEAD
Comment 3 GNOME Infrastructure Team 2021-07-05 14:13:40 UTC
GNOME is going to shut down bugzilla.gnome.org in favor of  gitlab.gnome.org.
As part of that, we are mass-closing older open tickets in bugzilla.gnome.org
which have not seen updates for a longer time (resources are unfortunately
quite limited so not every ticket can get handled).

If you can still reproduce the situation described in this ticket in a recent
and supported software version, then please follow
  https://wiki.gnome.org/GettingInTouch/BugReportingGuidelines
and create a new ticket at
  https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/

Thank you for your understanding and your help.