v0.12.0
Frequenz Repository Configuration Release Notes
Summary
This release introduces a new MkDocs macros pluglet system that simplifies documentation setup and provides enhanced functionality for version information and code annotations. It also includes changes to how pytest warnings are handled in templates.
Upgrading
-
The
nox
defaultpytest
session doesn't pass-W=all -vv
topytest
anymore. You can use thepyproject.toml
file to configure default options forpytest
, for example:[tool.pytest.ini_options] addopts = "-W=all -Werror -Wdefault::DeprecationWarning -Wdefault::PendingDeprecationWarning -vv"
Cookiecutter template
All upgrading should be done via the migration script or regenerating the templates.
curl -sSL https://raw.githubusercontent.com/frequenz-floss/frequenz-repo-config-python/v0.12.0/cookiecutter/migrate.py | python3
But you might still need to adapt your code:
-
pytest
now uses-Werror
by default (but still treat deprecations as normal warnings), so if your tests run with warnings, they will now be turned to errors, and you'll need to fix them. -
Projects using
docs/_scripts/macros.py
with customized scripts can use the new provided utility functions. See themkdocstrings_macros
documentation for the new features and setup.
New Features
- Two new modules were introduced to facilitate the configuration of
macros
for use within docstrings viamkdocstrings
:mkdocstrings_macros
andannotations
.
Cookiecutter template
pytest
now uses-Werror -Wdefault::DeprecationWarning -Wdefault::PendingDeprecationWarning
by default. Deprecations are still treated as warnings, as when testing with thepytest_min
session is normal to get deprecation warnings as we are using old versions of dependencies.
Bug Fixes
Cookiecutter template
- Fixed a compatibility issue in the macros doc script with
mkdocsstrings
0.28.
What's Changed
- Clear release notes by @llucax in #334
- Make
pytest
treat warnings as errors by @llucax in #335 - Bump the required group with 2 updates by @dependabot in #336
- Bump types-markdown from 3.7.0.20240822 to 3.7.0.20241204 by @dependabot in #339
- Bump the required group with 7 updates by @dependabot in #337
- Bump types-pyyaml from 6.0.12.20240917 to 6.0.12.20241230 by @dependabot in #338
- Fix
mypy
error with setuptools 7.6.8 type hints by @llucax in #347 - Bump the required group across 1 directory with 5 updates by @dependabot in #348
- Bump isort from 5.13.2 to 6.0.0 by @dependabot in #346
- Bump black from 24.10.0 to 25.1.0 by @dependabot in #345
- Move mkdocstrings-macros integration to a library by @llucax in #349
- Fix wrong argument in migration script by @llucax in #350
Full Changelog: v0.11.0...v0.12.0