Skip to content

Commit faf4ab1

Browse files
peterjcJoaoRodrigues
authored andcommitted
Use autodoc_preserve_defaults = True
See sphinx-doc/sphinx#8771 autodoc_preserve_defaults was new in Sphinx 3.5
1 parent 4defb75 commit faf4ab1

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

.travis-tox.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ deps =
134134
rdflib
135135
reportlab
136136
scipy
137-
sphinx>=1.8.0
137+
sphinx>=3.5.0
138138
numpydoc==1.0.0
139139
pygments
140140
sphinx_rtd_theme

Doc/api/conf.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,7 @@
1919

2020
# If your documentation needs a minimal Sphinx version, state it here.
2121
#
22-
# needs_sphinx = '1.0'
23-
needs_sphinx = "1.8"
22+
needs_sphinx = "3.5"
2423

2524
# Add any Sphinx extension module names here, as strings. They can be
2625
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
@@ -110,6 +109,10 @@
110109
"exclude-members": "__dict__,__weakref__,__module__",
111110
}
112111

112+
# Experimental feature to preserve the default argument values of
113+
# functions in source code and keep them not evaluated for readability:
114+
autodoc_preserve_defaults = True
115+
113116
# To avoid import errors.
114117
autodoc_mock_imports = ["MySQLdb", "Bio.Restriction.Restriction"]
115118
if version > "1.77":

0 commit comments

Comments
 (0)