Skip to content

Commit

Permalink
Remove dependency on sphinx-autodoc-typehints (Qiskit/qiskit-metapack…
Browse files Browse the repository at this point in the history
…age#1716)

Since Sphinx 5, this has had first-party support.  This removes a docs
dependency that has caused us significant problems before due to its
instability, and the built-in handling in `autodoc` is much cleaner as
well.  This commit is a mirror of Terra commit dfcfa4a.
  • Loading branch information
jakelishman committed Apr 11, 2023
1 parent 8a2b98d commit b2e1b2a
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@
'sphinx.ext.mathjax',
'sphinx.ext.viewcode',
'sphinx.ext.extlinks',
'sphinx_autodoc_typehints',
'jupyter_sphinx',
'nbsphinx',
'sphinx_design',
Expand Down Expand Up @@ -161,6 +160,13 @@
autosummary_generate_overwrite = False
autoclass_content = 'both'

# Move type hints from signatures to the parameter descriptions (except in overload cases, where
# that's not possible).
autodoc_typehints = "description"
# Only add type hints from signature to description body if the parameter has documentation. The
# return type is always added to the description (if in the signature).
autodoc_typehints_description_target = "documented_params"

# Plot directive configuration
# ----------------------------

Expand Down

0 comments on commit b2e1b2a

Please sign in to comment.