autosummary generation considers NewType
instances to be data, but autodoc considers them a class
#11552
Milestone
NewType
instances to be data, but autodoc considers them a class
#11552
Describe the bug
PR #10700 (addressing #10480) updates autodoc to consider
NewType
instances to be classes. Within autosummary templates, NewType values are listed in theattributes
template parameter, notclasses
.Within the rendering of a
NewType
stub template, theobjtype
is stilldata
. autosummary documentation suggests that theobjtype
might benewtypedata
, but"newtypedata"
does not appear to occur anywhere in the code.When autodoc generate a function that has a parameter which is a
NewType
instance, the parameter is annotated with a:py:class:
reference, which fails to connect to theautodata
entry that was used to generate theNewType
stub.How to Reproduce
Minimal repro: repro.tar.gz
To repro:
$ tar xvf repro.tar.gz $ cd repro/ $ make
Example output:
File Contents:
index.rst
:repro.py
:conf.py
module.t.rst
Makefile
Environment Information
Sphinx extensions
Additional context
No response
The text was updated successfully, but these errors were encountered: