Broken file select dialog in Filebot Ubuntu snap package version

All your suggestions, requests and ideas for future development
Post Reply
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

I tried using Filebot from the Ubuntu Snap package today. Unfortunately I couldn't because the file select dialog (which pops up when you click 'Load' in Filebot) is broken in the Snap package version.

My TV and movie show files are under a partition mounted at /srv/TIMSDATA, and symlinked /TIMSDATA. The problem is that the old-style file select dialog in the Snap package version doesn't see this /TIMSDATA symlink, nor does it see anything under /srv/. The file select dialog from the deb package version is the modern QT one and works correctly.

See screenshots:
The correctly working file browse dialog from the deb version:
Image
https://imagebin.ca/v/3RX55eaNU3dm

The faulty 'old-style' one from the Snap package:
Image
https://imagebin.ca/v/3RX5AxfCcloc
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by rednoah »

snapd doesn't allow snap packages to access random file system resources. Snaps only have access to specific folders, such as your home folder, gvfs folder, media folder, etc. If you make up your own top-level folders, then those won't be accessible to snaps for security reasons.

@see viewtopic.php?f=11&t=5139
:idea: Please read the FAQ and How to Request Help.
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

I should've mentioned but I installed the filebot snap with --devmode. So the problem isn't permissions - I can browse into any directory under / that my user has access too. The problem is the file select dialog ignores certain directories
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by rednoah »

Unfortunately, I can't currently test or fix any issues with the Linux version.

If you have full access, and it's really just the file dialog that's the issue, then you can just use drag and drop instead.
:idea: Please read the FAQ and How to Request Help.
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

Unfortunately drag-and-drop doesn't work with the Snap version if I'm trying to drag in files from that directory (/TIMSDATA) which the file select dialog can't see. The error printed in the terminal is:

Code: Select all

GVFS: file:///TIMSDATA/Video/TV/Breaking%20Bad/Season%201 => java.io.FileNotFoundException: /TIMSDATA/Video/TV/Breaking Bad/Season 1
Can I ask, are you still building the DEB packages? If not, would it be ok to build them on Launchpad and make them available as a PPA?
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by rednoah »

1.
Does this path exist?

Code: Select all

/TIMSDATA/Video/TV/Breaking Bad/Season 1
If yes, then FileBot is denied from accessing it, either due to sandbox restrictions, or Unix permissions. Are you sure that you're using --devmode?


2.
You'll find the latest Debian packages here:
https://sourceforge.net/projects/filebo ... Bot_4.7.9/

:!: You can create your own PPA, but you'd have to commit to actively maintaining it indefinitely. However, for security reasons, I would only ever use DEB for systems that don't support SNAP.


3.
The "QT File Dialog" you refer to is the Nimbus LaF Java Swing File Dialog. However, if you're using the DEB you shouldn't be seeing this one. Likewise, the SNAP version should use the GTK File Dialog, but it shouldn't look like this, unless something is broken in the theme and it's defaulting back to the "old" look.

There's something fishy about your system. Have you tried any of this on a clean latest Ubuntu? If you mount shares with the GUI then GVFS will take care of mounting shares to the right mount point that SNAP packages have access to.
:idea: Please read the FAQ and How to Request Help.
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

For 1., yes the path definitely exists and yes I'm definitely using --devmode. If I wasn't then I wouldn't be able to access any directories in that file selection dialog apart from what's under my home directory (I've tested). There should be no permissions problem since the files under /TIMSDATA are owned by the user I'm running Filebot as, and the permissions are anyway fairly open - world-readable.

2. Thanks for the link to the DEB packages, I'll have to keep using those for the time being. I'll think about doing the PPA, but I guess it's a lot of work.

3. I use KDE (Kubuntu) and not GNOME, but I don't think there's anything odd with my system - GTK apps seem normal. Anyway, I'm creating a VM from scratch to test this in again. I'll let you know how I go.
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by rednoah »

1.
Strange. I guess snapd is not quite ready for prime time yet. Maybe you could report this issue in the snapd project so they can have a look and what's going on here.


2.
Yep, it is. Kinda why nobody (including myself) has bothered to do it. It's less pressing now that snapd supports automatic delta updates though, except in your case of course.


3.
I see. I guess it's not working right if Gnome / GTK isn't fully installed.
:idea: Please read the FAQ and How to Request Help.
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

I've just tested again, this time in a freshly installed Kubuntu VM. I still get the same problem - the file dialog is the old style one, see Image

I'll raise a bug with Canonical
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by rednoah »

Best to also run some tests on a clean Ubuntu install, just to show that it's working on one platform but not another.
:idea: Please read the FAQ and How to Request Help.
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

The VM was a clean install from the Ubuntu Server ISO image. I just installed kubuntu-desktop instead of ubuntu-desktop after installation. Anyway, I'll see if the canonical Devs say anything on those bugs
tk83
Posts: 8
Joined: 28 Jun 2017, 12:45

Re: Broken file select dialog in Filebot Ubuntu snap package version

Post by tk83 »

FWIW this is what the Canonical dev's said regarding theme support (i.e. why the file select dialog uses the ancient, broken old GTK style):
allowing snap packages to use system themes has been discussed at the snappy sprint in london last week, it is still a bit until this feature will be fully available ... until then you can use one of the snapcraft desktop parts in your snap to have at least some default themeing behaviour shipped with it. there are a few discussions about this on the forum at https://forum.snapcraft.io
The forum he's talking about has this post for example that might be useful:
https://forum.snapcraft.io/t/theme-for- ... ons/836/10
Post Reply