[tor-commits] [stem/master] Fix autodoc configuration
atagar at torproject.org
atagar at torproject.org
Thu May 14 23:31:54 UTC 2020
commit c78e068cef2569804c7cc50d00f2b3bd4a0e7f54
Author: Damian Johnson <atagar at torproject.org>
Date: Mon May 11 16:25:49 2020 -0700
Fix autodoc configuration
Autodoc deprecated its autodoc_default_flags configuration in version 1.8. As a
result with new Sphinx versions our API documentation is empty. Moving to their
new configuration mechanism...
https://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html#confval-autodoc_default_flags
---
docs/conf.py | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/docs/conf.py b/docs/conf.py
index 6535135b..247220f8 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -28,8 +28,12 @@ needs_sphinx = '1.1' # required for the sphinx-apidoc command
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode', 'roles']
-autodoc_member_order = 'bysource'
-autodoc_default_flags = ['members', 'show-inheritance', 'undoc-members']
+autodoc_default_options = {
+ 'members': True,
+ 'member-order': 'bysource',
+ 'show-inheritance': True,
+ 'undoc-members': True,
+}
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
More information about the tor-commits
mailing list