We’re currently in a Snap workshop at the Linux App Summit and we’ve encountered a curious issue:
This package (popey will post a link later) starts just fine in Ubuntu but when ran in Fedora 31, it just refuses to do start at all.
HOWEVER, after running snap run --gdb toggdesktop
(and pressing ‘c’ a few times to get to the point where gdb prints a ton of “Detaching after fork from child process XXXX” messages), it’s possible to start the snap normally (snap run toggldesktop
).
Also, the following symlinks get created in my $HOME folder:
lrwxrwxrwx. 1 root root 26 Nov 15 14:02 Music -> /root/../home/mbriza/Music
lrwxrwxrwx. 1 root root 27 Nov 15 14:02 Public -> /root/../home/mbriza/Public
lrwxrwxrwx. 1 root root 30 Nov 15 14:02 Templates -> /root/../home/mbriza/Templates
Removing them doesn’t prevent the app from starting again (until snapd.service
gets restarted).
I’ve just done a quick test on a fresh Fedora 31 VM, the app worked right away from your snap:
I wonder if the error you see could be caused by some cruft from old fontconfig (from old Fedora?)?
As for the snap run --gdb ...
, when you run this way, it runs the snap with root permissions (it’s a current limitation of our gdb handling), so it apparently fixes some stuff.
UPDATE: to clarify, the error I’m referring to (which I cannot reproduce) is the one quoted by popey on IRC:
“Fontconfig warning: FcPattern object weight does not accept value [0 210)”
This is the build of the same commit but done on my machine: http://ma.rtinbriza.cz/toggldesktop_v7.4.1019+git3.2e66cddca_multi.snap which doesn’t work. For some reason the other one works for me too, wth
We also tested a build from dashboard.snapcraft.io (done in the could) and it didn’t work for me either.
So sorry for the confusion. If I make sure to remove the package AND restart the snapd.service
, it just breaks with any version of the toggldesktop package.
We did a snap save
for both states and I’m uploading the list of files that get generated by it for both the working and broken cases (including shell escape sequences to mark broken symlinks and stuff):
http://ma.rtinbriza.cz/snapissue/broken.tree
http://ma.rtinbriza.cz/snapissue/works.tree
It’s not the ideal to send this information so please if you’re interested in a different format, let me know and I’ll reupload in a different way.
I’ve tried your second version of the snap (http://ma.rtinbriza.cz/toggldesktop_v7.4.1019+git3.2e66cddca_multi.snap) and it also worked for me, and I didn’t have any fontconfig warnings.
Do you see any errors/denials reported in system log when it refuses to work? (I’d suggest snap run --strace ...
but just discovred it doesn’t work on Fedora 31, I’m going to file a bug for it).
Also, can you do a quick test and create a new user on your system, start a new X session for him, and see if it works?
Actually, you can use strace, just make sure you install strace package from fedora repos, not strace-static snap as suggested by snap run, e.g. please do:
snap run --strace=-f toggldesktop
And see if it reveals anything interesting (and pastebin+link here).