Skip to content

Commit 1b2ae13

Browse files
committed
Bump version; update changelog
1 parent cea70e2 commit 1b2ae13

File tree

2 files changed

+21
-3
lines changed

2 files changed

+21
-3
lines changed

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,35 @@
11
# Changelog
2+
23
All notable changes to this project will be documented in this file.
34

45
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
56
and this project adheres to
67
[Semantic Versioning](https://semver.org/spec/v2.0.0.html).
78

9+
## [0.3.1] - 03/07/2023
10+
11+
### Fixed
12+
13+
- Fix previous broken build (did not include changes)
14+
815
## [0.3.0] - 15/11/2021
16+
17+
### Fixed
18+
919
- Fix parsing of empty dictionaries and `False` configuration values. These would
1020
previously be overridden by the downstream configuration.
1121

1222
## [0.2.0] - 28/09/2021
23+
24+
### Added
25+
1326
- Add none_overrides_value option. Before this change, None values would unexpectedly
1427
override previously configured values. Now, the previous value will be retained if
1528
newer values are None. The old behavior can be re-enabled with by setting the
1629
none_overrides_value argument of CascadeConfig to True.
1730

1831
## [0.1.0-a0] - 03/08/2020
32+
33+
### Added
34+
1935
- Initial release

cascade_config.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"""Cascading configuration from the CLI and config files."""
22

3-
__version__ = "0.3.0"
3+
__version__ = "0.3.1"
44

55
import json
66
import os
@@ -55,15 +55,17 @@ def _update_dict_recursively(self, original: Dict, updater: Dict) -> Dict:
5555
"""Update dictionary recursively."""
5656
for k, v in updater.items():
5757
if isinstance(v, dict):
58-
if not v: # v is not None, v is empty dictionary
58+
if not v: # v is not None, v is empty dictionary
5959
original[k] = dict()
6060
else:
6161
original[k] = self._update_dict_recursively(original.get(k, {}), v)
6262
elif isinstance(v, bool):
6363
original[k] = v # v is True or False
6464
elif v or k not in original: # v is not None, or key does not exist yet
6565
original[k] = v
66-
elif self.none_overrides_value: # v is None, but can override previous value
66+
elif (
67+
self.none_overrides_value
68+
): # v is None, but can override previous value
6769
original[k] = v
6870
return original
6971

0 commit comments

Comments
 (0)