You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
DOC: intersphinx fails to find the documentation for DTypeLike #23058
In my library I am using numpy types and Sphinx 6.1.3 with intersphinx extension. The mapping is set to numpy 1.22 ("numpy": ("https://numpy.org/doc/1.22", None)), although I tried 1.24 as well.
When building the documentation, Sphinx correctly picks up typing annotations involving ndarray and dtype, and makes them hyperlinks to numpy docs. But it fails to do so for DTypeLike:
docstring of <...>:1: WARNING: py:class reference target not found: numpy.typing.DTypeLike
Idea or request for content:
I wonder if it could be the consequence of the docs for members of numpy.typing being generated in a roundabout fashion (in numpy.typing.__init__.py). Perhaps it is a Sphinx issue?
Actually, after rebuilding the docs from scratch, the error is different: multiple errors like
docstring of <...>:1: WARNING: py:class reference target not found: numpy._typing._dtype_like._DTypeDict
So it seems that Sphinx expands the union that is DTypeLike, but then can't find docs for some of the constituents. Seems to be a Sphinx problem, the workaround being autodoc_type_aliases setting in the config. Sorry for the issue, closing.
Activity
fjarri commentedon Jan 21, 2023
Actually, after rebuilding the docs from scratch, the error is different: multiple errors like
So it seems that Sphinx expands the union that is
DTypeLike, but then can't find docs for some of the constituents. Seems to be a Sphinx problem, the workaround beingautodoc_type_aliasessetting in the config. Sorry for the issue, closing.