GIO used from within Gnome Shell extensions does not list GVfs remote mounts
Affected version
OS: Fedora 33 (Workstation Edition) x86_64
Kernel: 5.9.16-200.fc33.x86_64
DE: GNOME 3.38.2
Affects both Xorg and Wayland
Bug summary
Gnome shell extensions act as if GIO_USE_VFS
was set to local
and does not list remote mounts such as SFTP or Google Drive. Running the same GJS code in a terminal works fine or produces the same output as the shell extensions when using GIO_USE_VFS=local
.
I believe this is the issue behind some of the problems listed here: gnome-shell-extensions#161 (closed)
Steps to reproduce
- Mount a remote location using Nautilus
- Open Looking Glass with
Alt+F2
lg
- Run the following code in Looking Glass:
volumeMonitor = Gio.VolumeMonitor.get(); output=""; mounts = volumeMonitor.get_mounts(); for (mount of mounts) { output += "Name: " + mount.get_name() + " Native: " + mount.get_default_location().is_native() + "\n"; } output;
- Type
output
and press enter
What happened
You will get an output listing all of the mounts from the VolumeMonitor. Unlike the same code run in a terminal, the remote mount will not be listed
What did you expect to happen
Remote GVfs mounts should be included in the output
Relevant logs, screenshots, screencasts etc.
Sample output from Looking Glass:
Name: Media Native: true
Name: Games Native: true
Name: Data Native: true
Sample output from gjs on terminal
Name: user@gmail.com Native: false
Name: admin on server Native: false
Name: Media Native: true
Name: Games Native: true
Name: Data Native: true
Edited by Michael Lawton