Skip to content

Commit 38a1c34

Browse files
authored
Small fixes for Python 3.10 (#5044)
This is enough to get stubtest working (note that it's a little annoying to install mypy currently since typed-ast seems to have broken again on Python 3.10) Co-authored-by: hauntsaninja <>
1 parent 79113be commit 38a1c34

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

stdlib/shelve.pyi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import collections
1+
import collections.abc
22
from typing import Any, Dict, Iterator, Optional, Tuple
33

4-
class Shelf(collections.MutableMapping[Any, Any]):
4+
class Shelf(collections.abc.MutableMapping[Any, Any]):
55
def __init__(
66
self, dict: Dict[bytes, Any], protocol: Optional[int] = ..., writeback: bool = ..., keyencoding: str = ...
77
) -> None: ...

stdlib/types.pyi

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,4 +331,6 @@ if sys.version_info >= (3, 10):
331331
class NoneType:
332332
def __bool__(self) -> Literal[False]: ...
333333
EllipsisType = ellipsis # noqa F811 from builtins
334+
from builtins import _NotImplementedType
335+
334336
NotImplementedType = _NotImplementedType # noqa F811 from builtins

0 commit comments

Comments
 (0)