All notable changes to this project will be documented in this file.
The Major version 1.y.z is to be considered in development; things can break and change at any moment. The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
- Now
create_config
can take an extra argument, which changes the default value of the options, when writing the config file. This allows you to have a json file to "fill" the configuration when testing things (and have a valid configuration).
- Now
parse_config
doesn't validate the configuration while parsing. This makes the function do only one thing (better for debugging) and allows for easier testing and merging.
- Updated GitHub links in the pyproject.toml file.
- Added
get_options
as a getter to allow users to access the list of options of a TypeConfig object. - Added
get_types
as a getter to allow users to access the list of types of a TypeConfig object.
- Moved the type hints parameter from the methods to the class initialisation and changed the healing method's name from
heal_file
toheal_config
.
- Fixed a bug in
validate_config
, which would re-assign the options' value to the whole config (if the value was True, the config would now be "True" instead of {option: True}).
- Falsy values are now considered when merging (a
False
will be considered a set value, not something left un-set). This was a problem when usingargparse
's 'action="store_false"
. It also implies that when usingstore_false
orstore_true
and you don't desire a default False (which could overwrite the config file), you also need to specifydefault=None
.
- It's now possible to use multi-line strings for
help
andimportant_help
messages. - Changelog.md has been added to the project.
- Changed
add_option
'sconstraints
parameter toimportant_help
.