Open
Description
With python 3.8.1 documenting a dataclass leads to this warning:
WARNING: Cannot treat a function defined as a local function: "mod.Foo" (use @functools.wraps)
This only occurs in python 3.8.1, python 3.8.0 does not show this warning.
This is minimally reproducible with 3 files:
conf.py
project = "unit_test"
extensions = ["sphinx.ext.autodoc", "sphinx_autodoc_typehints"]
source_suffix = ".rst"
master_doc = "doc"
doc.rst
Doc
###
.. automodule:: mod
:members:
mod.py
from dataclasses import dataclass
@dataclass
class Foo:
pass
Command used:
python3.8 -m sphinx . build
Relevant versions:
Sphinx==2.3.1
sphinx-autodoc-typehints==1.10.3