summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2014-03-20 15:38:52 +0000
committerGerrit Code Review <review@openstack.org>2014-03-20 15:38:52 +0000
commitcdeaf306e9c75d735fc2c4e8472e500092a1e9ba (patch)
tree07cbe3bc9ad7029eca51b144bb0f78a02cfc8525
parentb79f90f7b248d6f66514d4d452fbc850d35045dd (diff)
parent9b15e68740cba443ff5d24d7f6bc542c0aa4a243 (diff)
downloadpecan-cdeaf306e9c75d735fc2c4e8472e500092a1e9ba.tar.gz
Merge "Document another configuration use case for the use of `__force_dict__`."
-rw-r--r--docs/source/configuration.rst18
1 files changed, 12 insertions, 6 deletions
diff --git a/docs/source/configuration.rst b/docs/source/configuration.rst
index 1118c72..d1f9f83 100644
--- a/docs/source/configuration.rst
+++ b/docs/source/configuration.rst
@@ -182,13 +182,14 @@ string argument if you need to prefix the keys in the returned dictionary.
{'prefixed_app': {'prefixed_errors': {}, 'prefixed_template_path': '', 'prefixed_static_root': 'prefixed_public', [...]
-Dotted Keys and Native Dictionaries
------------------------------------
+Dotted Keys, Non-Python Idenfitiers, and Native Dictionaries
+------------------------------------------------------------
-Sometimes you want to specify a configuration option that includes dotted keys.
-This is especially common when configuring Python logging. By passing
-a special key, ``__force_dict__``, individual configuration blocks can be
-treated as native dictionaries.
+Sometimes you want to specify a configuration option that includes dotted keys
+or is not a valid Python idenfitier, such as ``()``. These situations are
+especially common when configuring Python logging. By passing a special key,
+``__force_dict__``, individual configuration blocks can be treated as native
+dictionaries.
::
@@ -197,6 +198,11 @@ treated as native dictionaries.
'root': {'level': 'INFO', 'handlers': ['console']},
'sqlalchemy.engine': {'level': 'INFO', 'handlers': ['console']},
'__force_dict__': True
+ },
+ 'formatters': {
+ 'custom': {
+ '()': 'my.package.customFormatter'
+ }
}
}