spacedrive
spacedrive copied to clipboard
[Linux] “Open with” only works with browsers
Describe the bug
Open with seams to only work with browsers (Firefox, Chrome, Edge) and not with e.g. Gimp, Inkscape or Okular (the file I tested with was a pdf).
Note that “Open in file manager” also opens Firefox (default web browser) for me instead of Dolphin (default file browser).
Clicking just “Open” also opens Firefox instead of Okular for pdf.
I also checked with different file managers (Okular and Deepin) and it worked as expected.
Reproduction
- right-click a PDF
- “Open with”
- Select any program which is not a web browser (I tested with Gimp, Inkscape, and Ocular)
- Doesn't open
- Repeat, but select a web browser (I tested with Chrome, Firefox, and Edge) and it opens.
Expected behavior
"Open with" should work
Platform and versions
Arch Linux, using the latest release from the action (697dfff).
Stack trace
No response
Additional context
No error messages logged.
"Open with" works for me with pdf files on non-browser applications, but I am on a Mac. I can't comment on the Open in file manager issue as that also seems to be a Linux thing.
@HeavenVolkoff can you take a look on this, sounds really weird.
@ModProg which DE are you using? Gnome? KDE? Or something else?
@ModProg which DE are you using? Gnome? KDE? Or something else?
I'm using sway. xdg-open
seams to work corectly.
In my case, I found that the AppImage version won't open any files that are not HTML and PDF (with double-clicking and with the “Open with” option), whilst the version I compiled from source will open any files in any circumstance.
Observation: The AppImage app will open the PDF on browsers and in the native document viewer, but will not open on Okular. The version built from source does not present the same issues.
Observation: The AppImage app will open the PDF on browsers and in the native document viewer, but will not open on Okular. The version built from source does not present the same issues.
I'll check that when I'm home.
@ModProg and @TheGB0077 I am building a release with some changes that I hope will fix this, could you guys test it: https://github.com/spacedriveapp/spacedrive/actions/runs/5516848084
The AppImage seems to still have the same behavior
The error remains for the most part, but some issues were fixed:
I got some errors on the terminal using the “Open with” option:
Opening a video
- With MPV (flatpak) errors:
/usr/bin/flatpak: /tmp/.mount_spacedRh2HJT/usr/lib/libjson-glib-1.0.so.0: no version information available (required by /usr/bin/flatpak)
/usr/bin/flatpak: /tmp/.mount_spacedRh2HJT/usr/lib/libselinux.so.1: no version information available (required by /lib/x86_64-linux-gnu/libostree-1.so.1)
/usr/bin/flatpak: symbol lookup error: /usr/bin/flatpak: undefined symbol: g_uri_get_port
- With the Default video app works
Opening an image:
- With Default image viewer (Eye of gnome) errors 🤔:
eog: symbol lookup error: /lib/x86_64-linux-gnu/libgirepository-1.0.so.1: undefined symbol: g_memdup2
- With Geeqie errors:
geeqie: /tmp/.mount_spacedRh2HJT/usr/lib/libjson-glib-1.0.so.0: no version information available (required by /lib/x86_64-linux-gnu/libclutter-1.0.so.0)
geeqie: symbol lookup error: /lib/x86_64-linux-gnu/libcogl.so.20: undefined symbol: wl_proxy_marshal_flags
-
With qimgv doesn't work, but there's no stacktrace
-
With ImageMagick works
Opening a PDF
- With default reader works as it did before, but there's also a related error:
/tmp/.mount_spacedRh2HJT/usr/lib/x86_64-linux-gnu/gio/modules/libgiognutls.so: não é possível abrir arquivo compartilhado: Permissão negada
Failed to load module: /tmp/.mount_spacedRh2HJT/usr/lib/x86_64-linux-gnu/gio/modules/libgiognutls.so
- With non Flatpak apps (Browsers, Koodo Reader) it works, but with Okular (Flatpak) it does not.
Ok, thanks @TheGB0077 and @ModProg, I think I know what's up now. AppImage works by changing some envvars to allow the app to use the internal deps instead of the system's one, and that is probably what's breaking launching externals apps, as this environment is inherited by them when we launch them, and they do not work with the internal deps shipped by our AppImage. I will implement some logic to avoid this and force the external apps to only use the system deps
@TheGB0077 and @ModProg, just released a new version with the aforementioned fixes (Only for the Open With
for now, if it works I will also fix the Open and the Reveal in file manager
), could you guys test it:
https://github.com/spacedriveapp/spacedrive/actions/runs/5526399805
Open with
is fixed, except when trying to open an image with the default image viewer, which now displays a different error:
Error
(eog:134313): Gtk-WARNING **: 00:24:56.953: im-cedilla.so: não é possível abrir arquivo compartilhado: Arquivo ou diretório inexistente
(eog:134313): Gtk-WARNING **: 00:24:56.953: Loading IM context type 'cedilla' failed
(eog:134313): Gtk-WARNING **: 00:24:56.969: im-cedilla.so: não é possível abrir arquivo compartilhado: Arquivo ou diretório inexistente
(eog:134313): Gtk-WARNING **: 00:24:56.969: Loading IM context type 'cedilla' failed
(eog:134313): Gtk-WARNING **: 00:24:56.979: Could not load a pixbuf from icon theme.
This may indicate that pixbuf loaders or the mime database could not be found.
(eog:134313): EOG-WARNING **: 00:24:56.979: Couldn't load icon: Failed to load /usr/share/icons/Pop/128x128/status/image-loading.svg: Não foi possível carregar o módulo de carregamento de imagens: libpixbufloader-svg.so: libpixbufloader-svg.so: não é possível abrir arquivo compartilhado: Arquivo ou diretório inexistente
(eog:134313): EOG-WARNING **: 00:24:56.979: Couldn't load icon: Failed to load /usr/share/icons/Pop/128x128/status/image-missing.svg: Não foi possível carregar o módulo de carregamento de imagens: libpixbufloader-svg.so: libpixbufloader-svg.so: não é possível abrir arquivo compartilhado: Arquivo ou diretório inexistente
**
Gtk:ERROR:../../../../gtk/gtkiconhelper.c:494:ensure_surface_for_gicon: assertion failed (error == NULL): Failed to load /usr/share/icons/Pop/16x16/status/image-missing.svg: Não foi possível carregar o módulo de carregamento de imagens: libpixbufloader-svg.so: libpixbufloader-svg.so: não é possível abrir arquivo compartilhado: Arquivo ou diretório inexistente (gdk-pixbuf-error-quark, 5)
Bail out! Gtk:ERROR:../../../../gtk/gtkiconhelper.c:494:ensure_surface_for_gicon: assertion failed (error == NULL): Failed to load /usr/share/icons/Pop/16x16/status/image-missing.svg: Não foi possível carregar o módulo de carregamento de imagens: libpixbufloader-svg.so: libpixbufloader-svg.so: não é possível abrir arquivo compartilhado: Arquivo ou diretório inexistente (gdk-pixbuf-error-quark, 5)
Reveal in file manager
crashes the app.
Edit:
Double-clicking does not work, except on html (unknown mime type, opens with gedit), pdf and extensionless files (unknown mime type, opens with gedit) (Same behavior as before).
Thanks, @TheGB0077, I will take a look why some gtk apps are still failing to launch, most likely I am setting up some XDG env vars wrong. But good to know that this fix the main problem, will implement it to the Open
/double click and the Reveal in file manager
too
@TheGB0077 Could you test this release: https://github.com/spacedriveapp/spacedrive/actions/runs/5559889374
It should fix all the remaining open issues (Reveal in file manager
and Double-clicking
)
@TheGB0077 Could you test this release: spacedriveapp/spacedrive/actions/runs/5559889374
It should fix all the remaining open issues (
Reveal in file manager
andDouble-clicking
)
Indeed, most issues have been solved, but some things are still not working as intended.
Reveal in file manager
just opens the file, instead of showing it on Nautilus.
The stutter reported on #1019 remains as well, the gst-plugin-scanner still hits several undefined symbols, but the thumb generation is not broken anymore.
Oh, I see that the issue is not linked to the PR anymore.
Reveal in file manager
just opens the file, instead of showing it on Nautilus.
Oh, that was an oversight mine, just pushed a commit that should fix this, a new release is building...
The stutter reported on #1019 remains as well, the gst-plugin-scanner still hits several undefined symbols, but the thumb generation is not broken anymore.
Oh, I see that the issue is not linked to the PR anymore.
Yeah, upon further investigation, this seems to be a deeper problem with how the script that Tauri
's bundler uses to create the AppImages
is handling the GStreamer
plugins. So I decided to tackle this issue in future PR.