diff --git a/stubs/atomicwrites/METADATA.toml b/stubs/atomicwrites/METADATA.toml index e20445253..6d3b92238 100644 --- a/stubs/atomicwrites/METADATA.toml +++ b/stubs/atomicwrites/METADATA.toml @@ -1,2 +1 @@ version = "1.4.*" -python2 = true diff --git a/stubs/atomicwrites/atomicwrites/__init__.pyi b/stubs/atomicwrites/atomicwrites/__init__.pyi index e1629cee4..8f5431d48 100644 --- a/stubs/atomicwrites/atomicwrites/__init__.pyi +++ b/stubs/atomicwrites/atomicwrites/__init__.pyi @@ -1,11 +1,12 @@ from _typeshed import StrOrBytesPath -from typing import IO, Any, AnyStr, Callable, ContextManager, Text +from collections.abc import Callable +from typing import IO, Any, AnyStr, ContextManager def replace_atomic(src: AnyStr, dst: AnyStr) -> None: ... def move_atomic(src: AnyStr, dst: AnyStr) -> None: ... -class AtomicWriter(object): - def __init__(self, path: StrOrBytesPath, mode: Text = ..., overwrite: bool = ...) -> None: ... +class AtomicWriter: + def __init__(self, path: StrOrBytesPath, mode: str = ..., overwrite: bool = ...) -> None: ... def open(self) -> ContextManager[IO[Any]]: ... def _open(self, get_fileobject: Callable[..., IO[AnyStr]]) -> ContextManager[IO[AnyStr]]: ... def get_fileobject(self, dir: StrOrBytesPath | None = ..., **kwargs: Any) -> IO[Any]: ...