Repository navigation
Conversation
A phone plugged in over USB (MTP) or a camera (PTP) showed nowhere, as Folio lists only mounted block devices. A bundled plugin lists what GVfs sees in a Phones section and mounts one through GVfs when opened, as Nautilus does.
[Medium impact] The PR appears safe to merge; both earlier findings are addressed and no new actionable issues were found. SummaryAdds the bundled
Reviews (2) · Last reviewed commit: "Report gio failing in the phones plugin,..." · Reviewed by Greptile |
A gio that couldn't list volumes left an empty Phones section and nothing in the journal; the plugin now fails with gio's own error. A test runs it against gio's output for a disk, a mounted phone and a camera whose name needs escaping, and against gio failing.
|
Thanks for this, it's a neat use of the plugin interface. It overlaps with #22, though, which makes Devices list GIO's volumes the way Nautilus does, mounted or not, and mounts one on a click. GIO's volume monitor includes the MTP and gphoto2 volumes, so with #22 a phone or camera should show under Devices with the drives (as it does in Nautilus) rather than in a section of its own, and without a 5-second So this one waits on #22. If #22 goes in and phones do show there, this isn't needed; if it doesn't, or phones turn out to need something it doesn't cover, this can be picked up again (rebased onto main, which it conflicts with now). If you have a phone handy, trying #22's branch with it would settle it quickly. |
A phone plugged in over USB showed nowhere in Folio: Devices lists mounted block devices, and a phone (MTP) or camera (PTP) is a GVfs volume instead. Nautilus lists them with the drives.
What changes
A bundled plugin,
phones, built only on what plugins.md describes:gio mount -lireports, every 5 seconds, so a phone shows up when it's unlocked and set to file transfer, and goes when it's unplugged.{"mount": "mtp://…", "verified": true}, so Folio mounts it through GVfs and goes to its storage.gio, from glib2, which Folio already depends on.The README and plugins.md now count it among the bundled plugins.
Tested with a OnePlus 13 over MTP. The suite passes.