Skip to content

Commit 6663149

Browse files
committed
DOC: Use the old class-based autodoc with Sphinx 9
The new version appears to be causing some issues for our missing reference checks, so reverting back to the old implementation should buy us some time to fix things.
1 parent cc62eba commit 6663149

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

doc/conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -899,3 +899,4 @@ def setup(app):
899899
if sphinx.version_info[:2] < (7, 1):
900900
app.connect('html-page-context', add_html_cache_busting, priority=1000)
901901
generate_ScalarMappable_docs()
902+
app.config.autodoc_use_legacy_class_based = True

lib/matplotlib/backend_tools.pyi

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,10 @@ class ToolHelpBase(ToolBase):
112112

113113
class ToolCopyToClipboardBase(ToolBase): ...
114114

115-
default_tools: dict[str, ToolBase]
115+
default_tools: dict[str, type[ToolBase]]
116116
default_toolbar_tools: list[list[str | list[str]]]
117117

118118
def add_tools_to_manager(
119-
toolmanager: ToolManager, tools: dict[str, type[ToolBase]] = ...
119+
toolmanager: ToolManager, tools: dict[str, type[ToolBase]] | None = ...
120120
) -> None: ...
121-
def add_tools_to_container(container: ToolContainerBase, tools: list[Any] = ...) -> None: ...
121+
def add_tools_to_container(container: ToolContainerBase, tools: list[Any] | None = ...) -> None: ...

0 commit comments

Comments
 (0)