-
Notifications
You must be signed in to change notification settings - Fork 141
Open
Labels
Description
As per title: directive .. autoapiclass does not respect autoapi_member_order = "bysource", and I'm not sure if there are others.
Here is a minimal working example: https://github.com/astrojuanlu/sphinx-autoapi-debug/tree/033f68fd
Even though testpkg.A has members c, a and b defined in this order, the rendered documentation gives a, b, and c:
Other things I found along the way:
- Initially I wrote
autoapi_dirs = [""]by mistake, and.. autoapiclass:: testpkg.Adidn't even give a warning. That made debugging more difficult. - I get several warnings saying
duplicate object description, probably because of the generatedautoapi/testpkg/index.rst(don't think this is unheard of, but at the moment I can't locate what would be the best way to avoid them):
$ make html
Running Sphinx v4.4.0
loading pickled environment... done
[AutoAPI] Reading files... [100%] /home/juanlu/Projects/Other/sphinx-autoapi-debug/src/testpkg/__init__.py
[AutoAPI] Mapping Data... [100%] /home/juanlu/Projects/Other/sphinx-autoapi-debug/src/testpkg/__init__.py
[AutoAPI] Rendering Data... [100%] testpkg
[autosummary] generating autosummary for: autoapi/index.rst, autoapi/testpkg/index.rst, index.rst
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 2 source files that are out of date
updating environment: 0 added, 2 changed, 0 removed
reading sources... [100%] autoapi/testpkg/index
/home/juanlu/Projects/Other/sphinx-autoapi-debug/docs/source/autoapi/testpkg/index.rst:38: WARNING: duplicate object description of testpkg.A, other instance in index, use :noindex: for one of them
/home/juanlu/Projects/Other/sphinx-autoapi-debug/docs/source/autoapi/testpkg/index.rst:42: WARNING: duplicate object description of testpkg.A.c, other instance in index, use :noindex: for one of them
/home/juanlu/Projects/Other/sphinx-autoapi-debug/docs/source/autoapi/testpkg/index.rst:47: WARNING: duplicate object description of testpkg.A.a, other instance in index, use :noindex: for one of them
/home/juanlu/Projects/Other/sphinx-autoapi-debug/docs/source/autoapi/testpkg/index.rst:53: WARNING: duplicate object description of testpkg.A.b, other instance in index, use :noindex: for one of them
Sothatsit and rickstaa
