evince from snap doesn't save position in pdf document

Bug #1795649 reported by Reverend Homer
78
This bug affects 42 people
Affects Status Importance Assigned to Milestone
Evince
New
Unknown
evince (Ubuntu)
Confirmed
Low
Unassigned

Bug Description

I've installed evince 3.30.0 (46) via "sudo snap install evince" on Ubuntu 18.04. Every time I'm running evince and opening pdf document, it opens the document on the first page, though I closed the document on the different page.

I can't reproduce that issue with evince installed via apt, so I think this is a snap-specific issue.

Also, every time I'm opening the document, evince prints the error:
Error registering document: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.evince.Daemon was not provided by any .service files

Tags: snap
tags: added: snap
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in evince (Ubuntu):
status: New → Confirmed
Revision history for this message
Mingun (alexander-sergey) wrote :

This still a problem in Ubuntu 20.04 and evince 40.4

See https://gitlab.gnome.org/GNOME/evince/-/issues/1642

When using snap-based evince the application state is not saved.

evince 40.4 from the snap of the Ubuntu 20.04 repositories:
  - does not save window position
  - does not save left pane state (it is always closed, after open it is always on the page "Thumbnails")
  - does not save page position
  - zoom seems to be "Fit Width", it seems that this is the default zoom
  - list of recently opened documents always empty

Also snap-based evince does not have an icon in the ubuntu-dock -- standard icon with gear in rhombus is used. evince from the apt has the icon with glasses on the printed list.

When I run evice from the command line I get the following output:

```
$ LC_ALL=C evince
Gtk-Message: 09:41:53.328: Failed to load module "canberra-gtk-module"
Gtk-Message: 09:41:53.399: Failed to load module "canberra-gtk-module"

(evince:154761): GLib-GIO-WARNING **: 09:42:47.490: Error creating IO channel for /proc/self/mountinfo: Permission denied (g-file-error-quark, 2)

(evince:154761): GLib-GObject-WARNING **: 09:42:47.549: invalid cast from 'GtkFileChooserNative' to 'GtkWidget'
Error registering document: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.evince.Daemon was not provided by any .service files
```

evice was installed as
```
sudo snap install evince
```

Changed in evince (Ubuntu):
importance: Undecided → Low
Changed in evince:
status: Unknown → New
Revision history for this message
John Johansen (jjohansen) wrote :

@Mingun: in https://bugs.launchpad.net/ubuntu/+source/evince/+bug/1969896 you reported this is still affecting Ubuntu 24.04.1

Can you provide log entries with the denials you are encountering?

  sudo dmesg | grep DENIED

Also you reported

  $ LANG=C sudo apparmor_parser -R /etc/apparmor.d/usr.bin.evince
  apparmor_parser: Unable to remove "/usr/bin/evince". Profile doesn't exist

can you provide what is returned by
  ls /etc/apparmor.d/usr.bin.evince

and
  sudo aa-status | grep evince

Revision history for this message
Mingun (alexander-sergey) wrote :
Download full text (11.6 KiB)

$ ls /etc/apparmor.d/usr.bin.evince
/etc/apparmor.d/usr.bin.evince

$ sudo aa-status | grep evince
   snap-update-ns.evince
   snap.evince.evince
   snap.evince.evince-previewer
   snap.evince.evince-thumbnailer
   snap.evince.hook.configure
   /snap/evince/1044/usr/bin/evince (1621044) snap.evince.evince

$ sudo dmesg | grep DENIED

[sudo] пароль для mingun:
[ 41.766220] audit: type=1400 audit(1725623682.916:192): apparmor="DENIED" operation="capable" class="cap" profile="/usr/lib/snapd/snap-confine" pid=1614 comm="snap-confine" capability=12 capname="net_admin"
[ 41.766237] audit: type=1400 audit(1725623682.916:193): apparmor="DENIED" operation="capable" class="cap" profile="/usr/lib/snapd/snap-confine" pid=1614 comm="snap-confine" capability=38 capname="perfmon"
[ 50.469773] audit: type=1400 audit(1725623691.620:194): apparmor="DENIED" operation="capable" class="cap" profile="/usr/sbin/cupsd" pid=1611 comm="cupsd" capability=12 capname="net_admin"
[ 64.740438] audit: type=1400 audit(1725623706.055:198): apparmor="DENIED" operation="capable" class="cap" profile="/usr/lib/snapd/snap-confine" pid=1974 comm="snap-confine" capability=12 capname="net_admin"
[ 64.740447] audit: type=1400 audit(1725623706.055:199): apparmor="DENIED" operation="capable" class="cap" profile="/usr/lib/snapd/snap-confine" pid=1974 comm="snap-confine" capability=38 capname="perfmon"
[ 65.535545] audit: type=1400 audit(1725623706.853:200): apparmor="DENIED" operation="open" class="file" profile="snap-update-ns.snapd-desktop-integration" name="/proc/2054/maps" pid=2054 comm="5" requested_mask="r" denied_mask="r" fsuid=121 ouid=0
[25563.291025] audit: type=1400 audit(1725649202.679:202): apparmor="DENIED" operation="capable" class="cap" profile="/usr/sbin/cupsd" pid=3605 comm="cupsd" capability=12 capname="net_admin"
[25564.189190] audit: type=1107 audit(1725649203.577:203): pid=1234 uid=103 auid=4294967295 ses=4294967295 subj=unconfined msg='apparmor="DENIED" operation="dbus_method_call" bus="system" path="/org/freedesktop/ColorManager/devices/cups_Kyocera_ECOSYS_M2040dn" interface="org.freedesktop.ColorManager.Device" member="AddProfile" mask="send" name="org.freedesktop.ColorManager" pid=1869 label="snap.cups.cupsd" peer_pid=1764 peer_label="unconfined"
[25564.189391] audit: type=1107 audit(1725649203.577:204): pid=1234 uid=103 auid=4294967295 ses=4294967295 subj=unconfined msg='apparmor="DENIED" operation="dbus_method_call" bus="system" path="/org/freedesktop/ColorManager/devices/cups_Kyocera_ECOSYS_M2040dn" interface="org.freedesktop.ColorManager.Device" member="AddProfile" mask="send" name="org.freedesktop.ColorManager" pid=1869 label="snap.cups.cupsd" peer_pid=1764 peer_label="unconfined"
[41445.511459] audit: type=1400 audit(1725665083.674:205): apparmor="DENIED" operation="open" class="file" profile="ubuntu_pro_esm_cache_systemd_detect_virt" name="/sys/firmware/dmi/entries/0-0/raw" pid=4625 comm="systemd-detect-" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
[111969.140765] audit: type=1400 audit(1725735601.864:206): apparmor="DENIED" operation="capable" class="cap" profile="/usr/sbin/cupsd" pid=7143 comm="cupsd" capability=12 capname="n...

Revision history for this message
Mingun (alexander-sergey) wrote :

$ ll /etc/apparmor.d/usr.bin.evince
-rw-r--r-- 1 root root 11133 авг 5 2021 /etc/apparmor.d/usr.bin.evince

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.