GNOME Bugzilla – Bug 757506
gsettings: schema_list should use the passed schema's source
Last modified: 2016-02-16 16:02:28 UTC
currently schema_list will iterate over the default SchemaSource list, and not the one associated with the passed in Schema. This means schema_list can give incorrect results for a Schema fetched from a non-default SchemaSource, like via new_from_directory. I was just trying some code via pygobject and hit this. I was basically doing: schema_source = Gio.SettingsSchemaSource.new_from_directory( "/my/test/dir", None, True) schema = schema_source.lookup(app_id, True) settings = Gio.Settings.new_full(schema, None, None) print settings.list_children() Which didn't list expected results, the list was empty. However if I added this before the code: os.environ["GSETTINGS_SCHEMA_DIR"] = "/my/test/dir" list_children() would return the expected results
Created attachment 314695 [details] [review] settings: schema_list should use the passed schema's source
ping, can someone review this?
Review of attachment 314695 [details] [review]: Nice spot! Thanks for the detailed commit message.
Thanks for the review. How to get this committed then?