Changes#
3.2.0 (13 Sep 2023)#
Use the standard library’s
tomllib
module on Python 3.11 and above and switch to tomli for earlier versions.
Thanks to Wim Glenn for the work!
3.1.0 (28 Nov 2022)#
Add support for deleting items and attributes via the
ConfigNode
interface.
3.0.0 (20 Sep 2022)#
Drop Python 2 support.
get()
can now be used without specifying a name to return the value of nodes representing simple attributes.Explicit support for
pathlib.Path
objects.
2.6.0 (5 Aug 2020)#
ConfigNode
instances can now bemerged
.Add support for an optional root in each file when using the “extends” pattern.
2.5.1 (4 Jun 2020)#
Change default false_values for
if_supplied()
to be atuple
rather afrozenset
, fixing a bug that occurred when source data wasn’t hashable.
2.5.0 (1 Jun 2020)#
Move the code for the “Config file that extends another config file” pattern into a helper function in
configurator.patterns.load_with_extends()
.
2.4.0 (31 May 2020)#
Allow the list of values considered false by
if_supplied()
to be specified.if_supplied()
no longer considersFalse
to be false, as when present, that’s often an explicitly provided value.
2.3.0 (27 May 2020)#
Config
instances can now be pickled.
2.2.0 (25 May 2020)#
value()
has been added to allow literal values to be used in the left side of mappings passed toConfig.merge()
.
2.1.0 (25 May 2020)#
Configuration values my now be set using attribute or item setting on
ConfigNode
instances.node()
can be used to obtain or create aConfigNode
from a dotted path and will give you a node even for a value of adict
or item in alist
.ConfigNode
instances now have aset()
method that can be used to replace the value of that part of the configuration, regardless of whether it is a container, list item or dictionary value.
2.0.0 (15 Apr 2020)#
Performance improvements when import parsers.
Removed the ability to provide new parsers using pkg_resources entry points.
1.3.0 (29 Jan 2020)#
Add
Config.from_env()
class method to help with extacting large numbers of environment variables into configuration.
1.2.0 (29 May 2019)#
Enable the context manager returned by
Config.push()
to return the state of a global config object to what it was beforepush()
was called.
1.1.0 (29 May 2019)#
1.0.0 (4 Apr 2019)#
Support for optional configuration files in
Config.from_path()
.Add
if_supplied()
mapping operation.Fully documented.
0.5.0 (15 Mar 2019)#
Initial release without docs.