"--device=usb" reports "Unknown device type usb" error

If flatpak is build with bellow manifest part it works fine.

finish-args:
- -- device=all

If manifest is changed to:

finish-args:
- -- device=usb

Github reports error:

error: Unknown device type usb, valid types are: dri, all, kvm, shm

If we look at the flatpak documentation the following is displayed: DEVICE must be one of: dri, input, usb, kvm, shm, all. so there is “usb” listed.

But what I see from github flatpak’s documentation:

This “–device=usb” was added to documentation 6 months ago. I assume at the same time this new feature was added.

On my Fedora and Ubuntu I have checked the flatpak software version with flatpak --version and for latest Fedora Silverblue “flatpak 1.16” version is displayed, but for Ubuntu 24.04 I see it still has “flatpak 1.14.6”.

Is there some flatpak version restriction for Flathub build packages, like minimum version flatpak software is required? If yes, what is flatpak software version currently Flathub.org flatpaks are targeted at?

For using the usb portal, it’s 1.16 - it will be years, before it can be used, as ubuntu is always slow at updating these.

There was a proposal, to fix this, but it was shut down.

1 Like

Don’t use that permission. It’s not widely available and Flathub will not accept it for that reason. Use device=all instead.