We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug Type hints are missing in constructors when autodoc_typehints = 'description'.
autodoc_typehints = 'description'
To Reproduce
PYTHONPATH=. sphinx-build -d "./_build" docs "_build/html" -b html -W --color
├── docs │ ├── conf.py │ └── index.rst └── myproject └── __init__.py
conf.py:
project = 'myproject' copyright = '2020, someone' author = 'someone' autodoc_typehints = 'description' extensions = [ 'sphinx.ext.autodoc', ] html_theme = 'alabaster'
myproject/__init__.py:
myproject/__init__.py
class A: """ :param boolean: I'm a boolean. """ def __init__(self, boolean: bool): pass
index.rst is minimal:
index.rst
Welcome to myproject's documentation! ===================================== .. automodule:: myproject :members: :imported-members:
Expected behavior Constructor parameter type hints should be documented.
Screenshots
With autodoc_typehints = 'description':
The type hint of bool should be in the description but it's missing.
bool
Without autodoc_typehints = 'description', bool is shown on the function prototype line as expected:
Environment info
The text was updated successfully, but these errors were encountered:
Thank you for reporting. This will be fixed by #8539.
Sorry, something went wrong.
Now #8539 is merged. It will be released as 4.0 soon. Thanks,
No branches or pull requests
Describe the bug
Type hints are missing in constructors when
autodoc_typehints = 'description'
.To Reproduce
PYTHONPATH=. sphinx-build -d "./_build" docs "_build/html" -b html -W --color
conf.py:
myproject/__init__.py
:index.rst
is minimal:Expected behavior
Constructor parameter type hints should be documented.
Screenshots
With
autodoc_typehints = 'description'
:The type hint of
bool
should be in the description but it's missing.Without
autodoc_typehints = 'description'
,bool
is shown on the function prototype line as expected:Environment info
The text was updated successfully, but these errors were encountered: