Accessing descriptors outside of a class doesn't work for parameters not explicitly defined in the configuration. Ie, according to UPGRADING,
If you access settings outside of classes like this:
Setting("setting").value
Then you should just import ginkgo and do this:
ginkgo.settings.get("setting")
However, ginkgo.setttings.get() will return None for a "setting" not explicitly defined in the config, thus ignoring its "default" value. For example:
class C(Service):
host = settings.setting("xmlrpc_host", default="localhost")
port = settings.setting("xmlrpc_port", default=1729)
server = SimpleXMLRPCServer((settings.get('xmlrpc_host'), settings.get('xmlrpc_port')) )
if no values are explicitly given in the .conf.py file for xmlrpc_host and port, settings.get(...) will be None. Config.get() only checks self._settings, but ignores self._descriptors.
My question: is this the desired behavior or should Config.get indeed also check the defined _descriptors and return the default value if the given setting isn't found in self._settings?
Thanks!
David.