pdoc3 / pdoc

:snake: :arrow_right: :scroll: Auto-generate API documentation for Python projects
https://pdoc3.github.io/pdoc/
GNU Affero General Public License v3.0
1.11k stars 143 forks source link

missing docstrings of methods #426

Open emanueleromito opened 1 year ago

emanueleromito commented 1 year ago

Hi guys. Thanks for releasing and mantaining pdoc.

In my codebase, I have a class that inherits from an abstract class, and within this derived class, I have methods named "compute" that are decorated or modified by a wrapper. However, when generating the HTML documentation using pdoc, I noticed that the docstrings associated with these "compute" methods are missing in the generated documentation.

I have verified that the docstrings are present in the source code and are correctly formatted. However, they are not appearing in the generated HTML documentation. This issue seems to be specific to the "compute" methods within the derived class, as the docstrings for other methods are being displayed correctly.

misanthropicat commented 11 months ago

Have the same problem: any decorated method of any class inherited from abstract object has missing docstrings in generated HTML documentation. Any plans to fix it?

thatdc-reply commented 4 months ago

I am having the same issue: any method decorated with @ is omitted in the documentation

kernc commented 3 weeks ago

The behavior is based on this logic: https://github.com/pdoc3/pdoc/blob/d1136eafa45315bf5e89596197a24804e4790ee6/pdoc/__init__.py#L1045-L1059 https://github.com/pdoc3/pdoc/blob/d1136eafa45315bf5e89596197a24804e4790ee6/pdoc/__init__.py#L993-L1018 I don't know if it solves it, but now that inspect.getmembers_static() is available, we should probably see to using that instead of the above custom logic. Can somebody try it?