Omegaconf

Latest version: v2.3.0

Safety actively analyzes 683322 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

2.3.0

Features

- Support python3.11 ([1023](https://github.com/omry/omegaconf/issues/1023))
- Support interpolation to keys that contain a non-leading dash character ([880](https://github.com/omry/omegaconf/issues/880))
- OmegaConf now inspects the metadata of structured config fields and ignores fields where `metadata["omegaconf_ignore"]` is `True`. ([984](https://github.com/omry/omegaconf/issues/984))

Bug Fixes

- Fix an issue where merging of nested structured configs could incorrectly result in an exception ([1003](https://github.com/omry/omegaconf/issues/1003))

2.2.3

Bug Fixes

- Revert an accidental behavior change where implicit conversion from `Path` to `str` was disallowed. ([934](https://github.com/omry/omegaconf/issues/934))
- ListConfig sliced assignment now avoids partial updates upon error ([950](https://github.com/omry/omegaconf/issues/950))
- Fix a bug that caused OmegaConf to crash when processing attr classes whose field annotations contained forward-references. ([963](https://github.com/omry/omegaconf/issues/963))
- Improve error message when certain illegal type annotations (such as `typing.Sequence`) are used in structured configs. ([991](https://github.com/omry/omegaconf/issues/991))
- When parsing yaml: Disallow numbers with trailing underscore from being converted to float. ([838](https://github.com/omry/omegaconf/issues/838))

API changes and deprecations

- In structured config type hints, OmegaConf now treats `tuple` as equivalent to `typing.Tuple`, and likewise for `dict`/`Dict` and `list`/`List`. ([973](https://github.com/omry/omegaconf/issues/973))

2.2.2

Bug Fixes

- Revert an accidental behavior change where implicit conversion from `Path` to `str` was disallowed. ([934](https://github.com/omry/omegaconf/issues/934))
- Revert a behavior change where namedtuples and list subclasses were coerced to ListConfig. ([939](https://github.com/omry/omegaconf/issues/939))
- Fix a bug where the `oc.dict.values` resolver failed when passed a relative dotpath ([942](https://github.com/omry/omegaconf/issues/942))

2.2.1

2.2

OmegaConf now natively supports two new primitive types, `bytes` and `pathlib.Path`.

Features

- Support unions of primitive types in structured config type hints (`typing.Union`) ([144](https://github.com/omry/omegaconf/issues/144))
- Support nested container type hints in structured configs, e.g. dict-of-dict and list-of-list ([427](https://github.com/omry/omegaconf/issues/427))
- Improve support for optional element types in structured config container type hints (`typing.Optional`) ([460](https://github.com/omry/omegaconf/issues/460))
- Add support for `bytes`-typed values ([844](https://github.com/omry/omegaconf/issues/844))
- Add support for `pathlib.Path`-typed values ([97](https://github.com/omry/omegaconf/issues/97))
- `ListConfig` now implements slice assignment ([736](https://github.com/omry/omegaconf/issues/736))
- Enable adding a `ListConfig` to a `list` via the `ListConfig.__radd__` dunder method ([849](https://github.com/omry/omegaconf/issues/849))
- Add `OmegaConf.missing_keys()`, a method that returns the missing keys in a config object ([720](https://github.com/omry/omegaconf/issues/720))
- Add `OmegaConf.clear_resolver()`, a method to remove interpolation resolvers by name ([769](https://github.com/omry/omegaconf/issues/769))
- Enable the use of a pipe symbol `|` in unquoted strings in OmegaConf interpolations ([799](https://github.com/omry/omegaconf/issues/799))

Bug Fixes

- `OmegaConf.to_object` now works properly with structured configs that have `init=False` fields ([789](https://github.com/omry/omegaconf/issues/789))
- Fix bugs related to creation of structured configs from dataclasses having fields with a default_factory ([831](https://github.com/omry/omegaconf/issues/831))
- Fix default value initialization for structured configs created from subclasses of dataclasses ([817](https://github.com/omry/omegaconf/issues/817))

API changes and deprecations

- Removed support for `OmegaConf.is_none(cfg, "key")`. Please use `cfg.key is None` instead. ([547](https://github.com/omry/omegaconf/issues/547))
- Removed support for `${env}` interpolations. `${oc.env}` should be used instead. ([573](https://github.com/omry/omegaconf/issues/573))
- Removed `OmegaConf.get_resolver()`. Please use `OmegaConf.has_resolver()` instead. ([608](https://github.com/omry/omegaconf/issues/608))
- Removed support for `OmegaConf.is_optional()`. ([698](https://github.com/omry/omegaconf/issues/698))
- Improved error message when assigning an invalid value to int or float config nodes ([743](https://github.com/omry/omegaconf/issues/743))
- To conform with the `MutableMapping` API, the `DictConfig.items` method now returns an object of type `ItemsView`, and `DictConfig.keys` will now always return a `KeysView` ([848](https://github.com/omry/omegaconf/issues/848))

2.1.1

Features

- Add a throw_on_missing keyword argument to the signature of OmegaConf.to_container, which controls whether MissingMandatoryValue exceptions are raised. ([501](https://github.com/omry/omegaconf/issues/501))

Miscellaneous changes

- Update pyyaml dependency specification for compatibility with PEP440 ([758](https://github.com/omry/omegaconf/issues/758))
- Fix a packaging issue (missing sdist dependency) ([772](https://github.com/omry/omegaconf/issues/772))

Page 1 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.