-
When building the docs from this repo, warnings are issued on a decorated method:
The related decorator has type annotations. Could this be a bug in griffe? Repro with |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hello, I'd say it is caused by a combination of your wrapper and your docstring-inheritance extension. I'd recommend using Also, check out our official docstring-inheritance extension: https://mkdocstrings.github.io/griffe-inherited-docstrings/. It's probably less specific than your own though, but maybe will work for you too. One benefit is that it works statically too, so won't require dynamically importing objects like you do in your own extension. |
Beta Was this translation helpful? Give feedback.
Hello, I'd say it is caused by a combination of your wrapper and your docstring-inheritance extension. I'd recommend using
functools.wraps
on yourwrapper
function, see https://mkdocstrings.github.io/troubleshooting/#my-wrapped-function-shows-documentationcode-for-its-wrapper-instead-of-its-own. Otherwise your function docstrings is overwritten by the wrapper docstring.Also, check out our official docstring-inheritance extension: https://mkdocstrings.github.io/griffe-inherited-docstrings/. It's probably less specific than your own though, but maybe will work for you too. One benefit is that it works statically too, so won't require dynamically importing objects like you do in your own ex…