Request: auto-connection of removable-media for chromium

The chromium deb package is being transitioned to snap on 19.10, a call for testing was issued and one of the most frequent requests in the feedback we’ve gotten so far is to auto-connect the removable-media interface to allow people to save their downloads on external hard drives, and to upload files located there.

I know a similar request has been denied for firefox, but I’m hoping that given recent user feedback and the fact that portals are not working just yet, this can be re-considered, at least for chromium.


I have the same feelings for chromium as for firefox. Why aren’t portals working? My understanding was it was blocked on MIR which have since been completed so there shouldn’t be anything blocking this on Ubuntu. For systems without portals (which there shouldn’t be that many users relative to those that have portals once the SRU is done and it migrates out to flavors/derivatives), the snap could detect this and that removable-media isn’t connected and tell the user about that.

In terms of detecting, see: Request password-manager-service auto-connection for Storage Explorer

This should address any user experience issues. Without additional review criteria, I don’t see a reason to discard the previous vote so I’m removing this from our review queue. Please feel free to add more information as desired.

There are a few missing pieces for portals to work OOTB:

  • xdg-desktop-portal{,-gtk} needs to be installed on the host system by default (it’s not in 16.04 and in 18.04)
  • The snap needs to run with the GTK_USE_PORTAL=1 environment variable (that’s an easy change)
  • The application needs to use the GtkFileChooserNative API for file open/save dialogs. Chromium currently doesn’t. @jamesh had a look at the current implementation, and he says: « from a quick look, the main things that aren’t portable to GtkFileChooserNative are previews and custom filters ». I could have a go at porting it to the GtkFileChooserNative API, but it’s unclear whether upstream would accept the change, if it removes existing functionality. I filed crbug #981309 to inquire about it.

Now that is fix released for both xenial and bionic, perhaps we could explore updating a package to pull this in on desktop? Perhaps ubuntu-desktop?

I think @kenvandine is working on this already.

I’ve uploaded ubuntu-meta to bionic which adds those to the desktop seed, but it’s awaiting the SRU team. I’ve also submitted a merge proposal adding it for xenial that’s awaiting review.

After several discussions between snapd architects, security, advocacy and other reviewers, we’ve updated our removable-media criteria in our processes.

Applying the new criteria to this request, chromium is a major browser from an vetted, mature publisher. Granting auto-connection. This is now live.