diff --git a/CHANGES.rst b/CHANGES.rst index c97caebbecd..3559556be05 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -4,6 +4,9 @@ Release 7.3.5 (in development) Bugs fixed ---------- +* #12295: Re-export various objects from ``sphinx.domains.python._object`` + in ``sphinx.domains.python``. + Patch by Jacob Chesslo and Adam Turner. Release 7.3.4 (released Apr 17, 2024) ===================================== diff --git a/sphinx/domains/python/__init__.py b/sphinx/domains/python/__init__.py index 542911f8706..2c61cb84b68 100644 --- a/sphinx/domains/python/__init__.py +++ b/sphinx/domains/python/__init__.py @@ -36,6 +36,16 @@ from sphinx.environment import BuildEnvironment from sphinx.util.typing import ExtensionMetadata, OptionSpec +# re-export objects for backwards compatibility +# xref https://github.com/sphinx-doc/sphinx/issues/12295 +from sphinx.domains.python._object import ( # NoQA: F401 + PyField, + PyGroupedField, + PyTypedField, + PyXrefMixin, + py_sig_re, +) + logger = logging.getLogger(__name__) pairindextypes = {