[Snap] Support disconnecting firefox:home
Categories
(Core :: Widget: Gtk, defect)
Tracking
()
People
(Reporter: kiebitz, Unassigned)
References
(Blocks 2 open bugs)
Details
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:96.0) Gecko/20100101 Firefox/96.0
Steps to reproduce:
- I installed FF using
snap install firefox
. - I disconnected the home access,
snap disconnect firefox:home
- Firefox failed to use xdg-desktop-portals
Actual results:
Couldn't save any files
Expected results:
Detect snap environment correclty.
After setting widget.use-xdg-desktop-portal
manually to true, everything works
Comment 1•3 years ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Widget: Gtk' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.
Comment 2•3 years ago
|
||
This is because by default Firefox will use the portal only if packaged as a flatpak, or if GTK_USE_PORTAL
≠ 0 (see https://hg.mozilla.org/mozilla-central/rev/800142bdea708f819ee11fadcf08f6cf3170eb32).
This is not Debian-specific, it affects the snap everywhere.
Note that GTK_USE_PORTAL
isn't correctly honoured in 96.0.3, but it is in 97.0 (currently in the candidate channel, expected to be promoted to stable today).
Also note that while the portal works to open files in Firefox, there are a number of things that don't work correctly:
- using
xdg-open
to open an HTML file somewhere in your home directory results in an access denied page - saving an HTML document with images and other assets fails at the first attempt, and succeeds when retried, but assets aren't downloaded (bug #1664887)
- downloading a file (e.g. a .tar.xz archive) from a hyperlink silently fails, even with the "always ask where to save files" preference enabled
So I wouldn't recommend disconnecting the home
plug just yet.
Comment 3•2 years ago
|
||
Olivier, what should be the expected behavior if we disconnect home
? I can repro the issue, but my current understanding would be that without home
we can't really save, is this a wrong assumption?
Comment 4•2 years ago
|
||
That's right, I just tested in an Ubuntu 22.04 VM, and if home
is disconnected saving files fails. Also, as I pointed out in comment #2, using xdg-open
to open an HTML file somewhere in your home directory results in an access denied page.
Comment 5•2 years ago
|
||
If disconnecting this is not supposed to be supported and hence it is expected to break stuff, should we just RESOLVED:INVALID
this ? Given the root cause was GTK_USE_PORTAL
not being honored and this is now fixed.
Updated•2 years ago
|
Updated•2 years ago
|
Comment 6•2 years ago
|
||
Now widget.use-xdg-desktop-portal.file-picker=1
does not get it to work at all.
Updated•2 years ago
|
Description
•