Configs merge behavior in v 0.8.1 changed
ArtemHarchishin opened this issue · comments
Hello,
With new version 0.8.1, configs merge behavior changed.
Example:
import config
d = {
"path": {
"to": {
"value-a": "A",
"value-b": "B"
}
}
}
base_cfg = config.config_from_dict(d)
d = {
"path": {
"to": {
"value-a": "C"
}
}
}
cfg = config.config_from_dict(d)
cfg_set = config.ConfigurationSet(cfg, base_cfg)
path_config = cfg_set.get('path')
print(path_config)
>>> {'to.value-a': 'C'}
in version 0.7.0 it print
>>> {'to.value-a': 'C', 'to.value-b': 'B'}
Sorry for the delay, I'll look into it -- the 0.7.xx behavior should be the correct one
@ArtemHarchishin I believe I've fixed this in #52.
@chinghwayu, thank you for the PR!