Skip to content

Commit

Permalink
docs: add new option to documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
gschwaer committed Nov 29, 2021
1 parent 1caf482 commit 33bebf5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGES
Expand Up @@ -23,6 +23,8 @@ Features added
layout via CSS
* #9899: py domain: Allows to specify cross-reference specifier (``.`` and
``~``) as ``:type:`` option
* #9792: autodoc: Add new option for ``autodoc_typehints_description_target`` to
include undocumented return values but not undocumented parameters.

Bugs fixed
----------
Expand Down
8 changes: 8 additions & 0 deletions doc/usage/extensions/autodoc.rst
Expand Up @@ -622,8 +622,16 @@ There are also config values that you can set:
When set to ``"documented"``, types will only be documented for a parameter
or a return value that is already documented by the docstring.

With ``"returnvalue_and_documented_params"``, parameter types will only be
annotated if the parameter is documented in the docstring. The return type is
always annotated (except if it is ``None``).

.. versionadded:: 4.0

.. versionadded:: 4.4

New option ``'returnvalue_and_documented_params'`` is added.

.. confval:: autodoc_type_aliases

A dictionary for users defined `type aliases`__ that maps a type name to the
Expand Down

0 comments on commit 33bebf5

Please sign in to comment.