Add further types to `_INVALID_BUILTIN_CLASSES` (#13263)

This commit is contained in:
Adam Turner
2025-01-23 03:53:25 +00:00
committed by GitHub
parent 47bff3faea
commit ca2ab35d94
4 changed files with 116 additions and 3 deletions

View File

@@ -2588,7 +2588,7 @@ def test_autodoc_TYPE_CHECKING(app):
'',
' .. py:attribute:: Foo.attr1',
' :module: target.TYPE_CHECKING',
' :type: ~_io.StringIO',
' :type: ~io.StringIO',
'',
'',
'.. py:function:: spam(ham: ~collections.abc.Iterable[str]) -> tuple[~gettext.NullTranslations, bool]',

View File

@@ -1356,7 +1356,7 @@ def test_autodoc_type_aliases(app):
' docstring',
'',
'',
'.. py:function:: read(r: ~_io.BytesIO) -> ~_io.StringIO',
'.. py:function:: read(r: ~io.BytesIO) -> ~io.StringIO',
' :module: target.autodoc_type_aliases',
'',
' docstring',
@@ -1429,7 +1429,7 @@ def test_autodoc_type_aliases(app):
' docstring',
'',
'',
'.. py:function:: read(r: ~_io.BytesIO) -> my.module.StringIO',
'.. py:function:: read(r: ~io.BytesIO) -> my.module.StringIO',
' :module: target.autodoc_type_aliases',
'',
' docstring',