So, after some research:

1) gvfs is not responsible for automounting. It emits events when
devices appear and responds to requests to mount devices. As such, gvfs
is not responsible for deciding whether to give up on mount attempts or
not.

2) Instead, I believe the heavy lifting is done by gnome-settings-
daemon.

3) It respects a config key at /org/gnome/desktop/media-
handling/automount. If this key is set to false, then no attempts will
be made to auto-mount devices.

So, it seems you have a few options.

A) Note that the libmtp detect rule which catches android devices is not
based on ID. It runs a program called mtp-probe that checks the USB
interfaces exposed by the device. I feel certain that you can configure
the USB interfaces published by the device to exclude MTP if you don't
support it. Normal android devices must be able to do this if they use
UMS instead of MTP.

B) You can turn off automounting if you're just worried about your
development workflow.

C) You can file a g-s-d bug and ask them to implement some sort of back-
off failure handling policy.

Thanks!

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gvfs in Ubuntu.
https://bugs.launchpad.net/bugs/1160847

Title:
  gvfs should not attempt to mount MTP devices in an endless loop
  (cluttering your desktop with messages)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gvfs/+bug/1160847/+subscriptions

-- 
desktop-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

Reply via email to