Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Make Read the Docs include autodoc documentation for special-members?

I have a module with two documented global special-members.

Running Sphinx locally creates documentation that includes their docs, but Read the Docs doesn't. It uses the built-in type's documentation instead.

I have tried both styles: #: and docstring after the definition. I have read autodoc's documentation multiple times, and the Read the Docs entry on it. I can't figure out what I'm missing, as I don't even see any build errors on Read the Docs.

Any ideas?

like image 921
Márcio Avatar asked Jan 17 '15 20:01

Márcio


1 Answers

In case you are using Napoleon extension to handle NumPy or Google style docstrings, you can set a configuration flag for this in your conf.py

http://sphinx-doc.org/ext/napoleon.html?highlight=special#confval-napoleon_include_special_with_doc

If I remember correctly there is also a directive for autodoc:

http://sphinx-doc.org/ext/autodoc.html?highlight=member#event-autodoc-skip-member

By implementing this method you have a fine grained choice of which member is going to be included in the docs and which is not.

like image 130
marscher Avatar answered Oct 19 '22 21:10

marscher