-
-
Notifications
You must be signed in to change notification settings - Fork 63
Description
Description of the bug
When building docs for files generated via protobuf/grpc/mypy-protobuf, griffe complains about No type or annotation for parameter 'channel'. This generates a .py file that has docstrings with no type hints (code or docstrings), plus a .pyi file that has no docstrings but the code has type hints.
This used to work with griffe==1.14.0 and fails with griffe==1.15.0.
This is just a warning, but since we use strict=true it fails the build. We are working around it by using the option:
docstring_options:
warn_missing_types: falseTo Reproduce
You can have a look at the CI builds above, or just checkout the code before we added the fix: frequenz-floss/frequenz-api-dispatch@99ca855.
Here you also have a minimal project with protobuf-generated files with this issue:
frequenz-api-test.tar.gz
Something like:
uv venv --python 3.13 venv
. venv/bin/activate
SETUPTOOLS_SCM_PRETEND_VERSION=1.0.0 uv pip install .[dev]
mkdocs buildShould work, but you would need to have a working docker installation too 😬 because the build process will try to use docker to generate docs from the proto files too.
Environment information
- System: Linux-6.12.63+deb13-amd64-x86_64-with-glibc2.42
- Python: cpython 3.13.5 (/tmp/pytest-of-luca/pytest-4/test_generation_RepositoryType0/frequenz-api-test/venv/bin/python3)
- Environment variables:
- Installed packages:
griffev1.15.0