GNOME Bugzilla – Bug 707783
Minor rewording of documentation to avoid confusion
Last modified: 2013-09-10 15:46:50 UTC
Reading keys directly from the database is no problem. For example this works: sworddragon@ubuntu:~$ dconf read /org/gtk/settings/file-chooser/show-hidden true But doing a write operation can make troubles: sworddragon@ubuntu:~$ dconf write /org/gtk/settings/file-chooser/show-hidden false error: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name ca.desrt.dconf was not provided by any .service files Usage: dconf write KEY VALUE Write a new value to a key Arguments: KEY A key path (starting, but not ending with '/') VALUE The value to write (in GVariant format) dconf has forwarded the request to dbus (dconf-service). But the manpage says: "This tool operates directly on the dconf database and does not read gsettings schema information." This seems to be true for read operations but not for write operations.
(In reply to comment #0) > error: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name > ca.desrt.dconf was not provided by any .service files This looks like an installation problem. The service file should be installed in the usual place, relative to your install prefix. Please check your install (if you compiled yourself) or take the issue up with your distribution otherwise. It may be necessary to add extra paths to your D-Bus service search path if you installed somewhere other than /usr.
I have explicitly disabled dbus services. But as already said dconf should not be affected by this otherwise the manpage is wrong.
The "directly" that you are reading from this sentence is clearly in reference to GSettings schemas, not D-Bus. It's a pretty tough sell to tell me that you honestly thought that this was in reference to D-Bus... If you want to have support for writing with dconf, you must use D-Bus. There are quite a lot of reasons for that. The two largest ones are that using a D-Bus service ensures that there are no consistency issues caused by multiple writers (since they have to serialise through the same service) and that D-Bus is used for sending change notifications (which is a core feature of dconf). I have no plans to change this. In any case, I suppose I can reword this sentence to be more strictly correct.
Created attachment 254604 [details] [review] Clarify statements about not using schemas Reword the note in the documentation about not using GSettings schemas so that it cannot be taken to mean that the commandline tool doesn't use D-Bus.
Attachment 254604 [details] pushed as fec9891 - Clarify statements about not using schemas
Thanks for the change. But this also means that I'm not able to operate on a dconf database directly. dconf and gsettings can only write over D-Bus to the database. service-db:keyfile/user will just move the binary database to the cache which still requires D-Bus to update from the textfile. It seems I have to write my own tool to write directly to the database.