pwmt / zathura

Document viewer
https://pwmt.org/projects/zathura
zlib License
2.05k stars 141 forks source link

HTTPS URL open #640

Closed hholst80 closed 3 weeks ago

hholst80 commented 2 months ago

This is a feature request.

I would like to be able to open https:// links directly to PDFs from Zathura.

As far as my version goes, 0.5.6, I cannot do this.

# za "https://freetestdata.com/wp-content/uploads/2021/09/Free_Test_Data_100KB_PDF.pdf"
info: Opening plain database via sqlite backend.
warning: sqlite database already exists. Set your database backend to sqlite
error: Can not copy to temporary file: Operation not supported
sebastinas commented 2 months ago

Do you have the sandbox enabled?

sebastinas commented 1 month ago

Closing for now.

hholst80 commented 1 month ago

No sandbox.

# file /usr/bin/zathura
/usr/bin/zathura: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=ebc7e25d24b501c5b382e02c3c4238faecceff05, for GNU/Linux 4.4.0, stripped
[I] root@trump ~ 
# /usr/bin/zathura ^C
[I] root@trump ~ 
# /usr/bin/zathura "https://freetestdata.com/wp-content/uploads/2021/09/Free_Tes
t_Data_100KB_PDF.pdf"
error: Can not copy to temporary file: Operation not supported
[I] root@trump ~ 
# /usr/bin/zathura --version
zathura 0.5.6
girara 0.4.4 (runtime: 0.4.4)
(plugin) pdf-poppler (0.3.2) (/usr/lib/zathura/libpdf-poppler.so)
[I] root@trump ~ 
# 
hholst80 commented 1 month ago

@sebastinas care to re-open if this is a feature you could consider? it is reasonably easy to implement with a wrapper but I would think a streaming I/O to be more efficient not having to download the entire PDF to start reading it.

sebastinas commented 1 month ago

I think in that case we'll need the output of strace to check what is happening.

hholst80 commented 3 weeks ago

strace.log

hholst80 commented 3 weeks ago

@sebastinas to be clear, this works for you? perhaps there is something special then with my system?

sebastinas commented 3 weeks ago

Yes, this works for me. I cannot see a reason why this fails in the strace log. g_file_copy should also not fail with this type of error. Do you have a special build of glib/gio?

hholst80 commented 3 weeks ago

No nothing. But I do use a non standard desktop environment with RiverWM and I am also not sure about the precise setup of dbus.

sebastinas commented 3 weeks ago

Do you have gvfs-backends installed? That's required for https support.

hholst80 commented 3 weeks ago

I installed it but it made no difference - same error message.

I think the dbus system is a mess I don't want to have on my computer, so I might have to give up on this feature then if it requires both the delicate mechanisms of dbus to work, and gnome libraries.

https://forum.artixlinux.org/index.php/topic,2861.0.html

sebastinas commented 3 weeks ago

Okay, without working gvfs opening https:// links with zathura won't work.