Feature Freeze Exception: Seeding the official Firefox snap in Ubuntu Desktop

When the firefox snap crashes because of a background snap refresh (see this bug), relaunching it from the crash reporter dialog will indeed result in broken behaviour. The workaround in that case is to close the dialog, and launch firefox again. If the crash wasn’t caused by some dependencies disappearing under firefox’s feet, then relaunching from the crash reporter dialog should work just fine.

1 Like

image

I do not have any experience with OpenSC and it seems to be possible to use it without pcsc daemon.

But indeed it should be possible to package it as a snap and provide the same functionality and content interface my pcsc-daemon snap offers for someone who is more familiar with it.

One issue I can see currently with snaps, that this sandboxing prevents some other applications to function propperly.

For example the interaction of browser extension keepassxc-browser is not possible through snaps (currently). So this change would break many users daily workflow.

And there is still an issue in snap that prevents it from working propperly. E.g. in some enterprises the user homes are not in /home but somewhere else on the filesystem and /home is used with automount to access network homes - this does not work with snap and therefore from my perspective it is unacceptable to remove any key-functionality like Firefox from the normal “deb” way.

2 Likes

Few bits of feedback from me. I can turn these into bug reports, and check if they’re already reported, if that’s helpful (is that on firefox with the snap tag? It would be good to document that on the snap’s page) - sorry they’re not very detailed, I was doing other things when I noticed these issues. Also sorry I didn’t read through all 85 posts here so these may have been discussed already :smiley:

I was using beta, 93b8 at the time (I see b9 is out now), in a GNOME/Wayland session. I had manually imported my profile from the .deb installation I had before. This is on Impish.

  • Something was initially wrong with fonts. In Google Docs, “Sans Serif” was actually some serif font. After a reboot the fonts were OK again.
  • Similarly, cursors aren’t/weren’t (not sure if this one fixed itself) available - I got no ‘hand’ icon when hovering links, and no ‘I bar’ for text.
  • Screen sharing didn’t work e.g. in Meet. I guess this might be a Wayland thing but it was ok with the deb. I got the portal UI (which is great and I wish you didn’t have to go through the ‘Use system dialog’ [or whatever it is] step to see it) but after selecting the target sharing never started, and the screen sharing button in the Meet UI goes insensitive so you can’t retry until restarting. Not that it would have worked!
  • I couldn’t open links from the VS Code snap any more. I got that dialog which you sometimes see about Firefox not responding, even though it was working fine AFAICT.
2 Likes

You just lost another user of FF. Snap eats up space on my disk and initially does give trouble with new ad on applications. Sorry that is my experience. I quite Chromium be cause of this.

$ snap info firefox|grep installed
installed:          92.0-3                  (595) 159MB -
$ apt-cache show firefox | grep Installed
Installed-Size: 221407

the installed firefox snap is exactly 60MB smaller than the installed deb …

note that snap packages (unlike debs) do not get unpacked but only bind-mounted (as compressed, gpg signed (and thus tinker proof) readonly filesystem images)…

snaps are typically significantly smaller than what you get when installing the equivalent content on disk from debs.

9 Likes

Just out of curiosity: How do you install the Firefox deb without using disk space?

Problem with google earth can easily be reproduced with samples in https://www.khronos.org/webgl/wiki/Demo_Repository
occurs only in Wayland session but DOES NOT OCCUR with X11 session.

1 Like

It is the snap updates , leaves snap never self removed. Unless I missed a auto remove of the snap processing. over time the snap builds up.

snap packages have a builtin rollback mechanism as well as a builtin self-test mechanism …

i.e. if an apache snap is updated you can define that it checks for port 80 to be open after an upgrade … if that test fails, it will automatically roll back to the last known good version on disk to guarantee operation of the app/service (though admittedly desktop snaps do not use that feature a lot)) …

along with that, if your firefox snap is released with a bug or a new feature is broken you can always manualy do snap revert firefox

for this feature the last good snap as well as the current snap are always kept around …

you can define the number of snaps to keep with sudo snap set system refresh.retain=2 (2 is the minimum here) as documented in:

while this indeed means you always have the same snap installed two times, the snap compression usually compensates this … while they do occupy more disk space, it is usually not a lot more than their unpacked equivalent in deb or rpm …

2 Likes

Did you consider spellchecking in other languages than English (US)?

I made a Swedish install from the latest daily build. As expected the Swedish dictionary for spellchecking is present at first login in /usr/share/hunspell and can be used directly by several common programs. Confirmed with LibreOffice Writer and gedit. And if Firefox had been installed as an APT package, Swedish spellchecking would have worked out of the box in Firefox too.

But in the Fixefox snap only English (US) spellchecking is available to start with. I suppose the reason is that the snap does not see /usr/share/hunspell.

I can download and install Swedish spellchecking from Mozilla as an extension. If I do, it ends up as a compiled .xpi file in my Firefox profile in the ~/snap/ directory. (And it’s actually the same dictionary as I already have in /usr/share/hunspell.)

Nevertheless, the need to figure out how to do that is an unfortunate regression in my opinion. Ubuntu users expect spellchecking to work out of the box also in Firefox. So it would be highly desirable if the AppArmor profile could be modified so also the Firefox snap sees and can make use of the dictionaries in /usr/share/hunspell.

9 Likes

I think one way to improve the situation is what I have proposed here Proposal: Use casync for delta updates - snapd - snapcraft.io – i.e. instead of keeping the whole snap of the old revisions, only keep the delta, that can be used to reconstruct the old revision from the latest install snap as the “seed”. It helps both the IoT case as well as the Desktop case.

3 Likes

Hey Gunnar, spellchecking has been discussed there before Desktop: allow access to host hunspell dictionaries - snapd - snapcraft.io , it doesn’t seem to be resolved at the time though and isn’t as easy as granting access to one directory

2 Likes

On my Ubuntu 21.10 some time ago i installed firefox snap and then removed it. Now with the updates i don’t see FF snap reinstalled. Should i reinstall ‘by hand’?
thanks.

The snap will be installed automatically in the following scenarii:

  • installing a fresh 21.10 from a recent ISO
  • dist-upgrading from 21.04

If you dist-upgraded some time ago, the change wasn’t in place yet, so yes, you’ll need to re-install the snap manually (if that’s what you want to use, otherwise the deb remains available and supported).

1 Like

Thanks for the feedback @laney!

Your issue with cursors is very likely https://gitlab.gnome.org/Community/Ubuntu/gnome-sdk/-/issues/6.

For any issue that didn’t fix itself automagically and which you can still reproduce, bug reports are welcome on the upstream tracker (make sure to mention “snap” in the bug title for easier triaging). I’m personally triaging and investigating all of them.

2 Likes

Thanks, in fact on my Ubuntu 21.10 installed from Beta I found FF snap and manually installed FF deb to compare, while on my Ubuntu 21.10 installed from an older ISO i see only FF deb.
Thanks again.

Four years ago… But now maybe the most important desktop application — Firefox — will be provided as a snap, and spellchecking is an important aspect of the typing experience. I can just say: Please give this issue some priority. It would be sad if it would still be present at the 22.04 release.

12 Likes

You’re right Gunnar. Strictly speaking, this is a functional regression, so that’s not looking good.

I filed upstream bug 1732755 to keep track of it. As has already been discussed in the past, there’s no obvious and easy to implement solution, but we’ll work something out. Suggestions welcome.

9 Likes