saber-notes / saber

The cross-platform open-source app built for handwriting
https://saber.adil.hanney.org
GNU General Public License v3.0
2.34k stars 152 forks source link

[Bug] AppImage won't start #1124

Open Drsheppard01 opened 9 months ago

Drsheppard01 commented 9 months ago

Before submitting an issue, please check the following

Describe the bug

When i try to start Saber AppImage i get output:

(saber:10555): Gtk-WARNING **: 06:33:37.693: Could not load a pixbuf from icon theme.
This may indicate that pixbuf loaders or the mime database could not be found.
**
Gtk:ERROR:../../../../gtk/gtkiconhelper.c:494:ensure_surface_for_gicon: assertion failed (error == NULL): Failed to load /org/gtk/libgtk/icons/16x16/status/image-missing.png: Unrecognized image file format (gdk-pixbuf-error-quark, 3)
Bail out! Gtk:ERROR:../../../../gtk/gtkiconhelper.c:494:ensure_surface_for_gicon: assertion failed (error == NULL): Failed to load /org/gtk/libgtk/icons/16x16/status/image-missing.png: Unrecognized image file format (gdk-pixbuf-error-quark, 3)
[1]    10555 IOT instruction (core dumped)  /home/(my name)/Applications/Saber-0.19.2-x86_64.AppImage

To reproduce

  1. Download AppImage
  2. Execute AppImage
  3. Get wrong

Expected behavior

  1. Download AppImage
  2. Execute AppImage
  3. Be happy

Saber version

0.19.2-x86_64.AppImage

Device

Anything else?

I looked at the path that's used before the icon and it looks like it's ./gtk/gtk/icons https://github.com/GNOME/gtk/tree/main/gtk/icons

Related issue: AppImage/AppImageKit/issues/481 Resolve: https://github.com/AppImageCrafters/AppRun/blob/master/docs/USAGE.md#recommended-environment-entries

Drsheppard01 commented 9 months ago

I see that the GTK_PATH variable refers to /usr/lib/x86_64-linux-gnu/gtk-3.0, which is missing from the /usr/lib/x86_64-linux-gnu/ directory in the unzipped appimage, also the icons are in /usr/share/icons/Humanity/status and the image-missing file has svg instead of png resolution

Drsheppard01 commented 9 months ago

After a little investigation I just added the directories /usr/share/ and /usr/local/share and the application ran Now the line looks like: XDG_DATA_DIRS=$APPDIR/usr/share:$APPDIR/usr/local/share:/usr/share:$XDG_DATA_DIRS