diff --git a/stdlib/codecs.pyi b/stdlib/codecs.pyi index ee1ab25bac47..acbf23b5992a 100644 --- a/stdlib/codecs.pyi +++ b/stdlib/codecs.pyi @@ -223,7 +223,7 @@ class Codec: # These are sort of @abstractmethod but sort of not. # The StreamReader and StreamWriter subclasses only implement one. def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder: errors: str diff --git a/stdlib/encodings/cp037.pyi b/stdlib/encodings/cp037.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp037.pyi +++ b/stdlib/encodings/cp037.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1006.pyi b/stdlib/encodings/cp1006.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1006.pyi +++ b/stdlib/encodings/cp1006.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1026.pyi b/stdlib/encodings/cp1026.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1026.pyi +++ b/stdlib/encodings/cp1026.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1125.pyi b/stdlib/encodings/cp1125.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp1125.pyi +++ b/stdlib/encodings/cp1125.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1140.pyi b/stdlib/encodings/cp1140.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1140.pyi +++ b/stdlib/encodings/cp1140.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1250.pyi b/stdlib/encodings/cp1250.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1250.pyi +++ b/stdlib/encodings/cp1250.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1251.pyi b/stdlib/encodings/cp1251.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1251.pyi +++ b/stdlib/encodings/cp1251.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1253.pyi b/stdlib/encodings/cp1253.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1253.pyi +++ b/stdlib/encodings/cp1253.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1254.pyi b/stdlib/encodings/cp1254.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1254.pyi +++ b/stdlib/encodings/cp1254.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1255.pyi b/stdlib/encodings/cp1255.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1255.pyi +++ b/stdlib/encodings/cp1255.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1256.pyi b/stdlib/encodings/cp1256.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1256.pyi +++ b/stdlib/encodings/cp1256.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1257.pyi b/stdlib/encodings/cp1257.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1257.pyi +++ b/stdlib/encodings/cp1257.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp1258.pyi b/stdlib/encodings/cp1258.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp1258.pyi +++ b/stdlib/encodings/cp1258.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp273.pyi b/stdlib/encodings/cp273.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp273.pyi +++ b/stdlib/encodings/cp273.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp424.pyi b/stdlib/encodings/cp424.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp424.pyi +++ b/stdlib/encodings/cp424.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp437.pyi b/stdlib/encodings/cp437.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp437.pyi +++ b/stdlib/encodings/cp437.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp500.pyi b/stdlib/encodings/cp500.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp500.pyi +++ b/stdlib/encodings/cp500.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp720.pyi b/stdlib/encodings/cp720.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp720.pyi +++ b/stdlib/encodings/cp720.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp737.pyi b/stdlib/encodings/cp737.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp737.pyi +++ b/stdlib/encodings/cp737.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp775.pyi b/stdlib/encodings/cp775.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp775.pyi +++ b/stdlib/encodings/cp775.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp850.pyi b/stdlib/encodings/cp850.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp850.pyi +++ b/stdlib/encodings/cp850.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp852.pyi b/stdlib/encodings/cp852.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp852.pyi +++ b/stdlib/encodings/cp852.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp855.pyi b/stdlib/encodings/cp855.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp855.pyi +++ b/stdlib/encodings/cp855.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp856.pyi b/stdlib/encodings/cp856.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp856.pyi +++ b/stdlib/encodings/cp856.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp857.pyi b/stdlib/encodings/cp857.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp857.pyi +++ b/stdlib/encodings/cp857.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp858.pyi b/stdlib/encodings/cp858.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp858.pyi +++ b/stdlib/encodings/cp858.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp860.pyi b/stdlib/encodings/cp860.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp860.pyi +++ b/stdlib/encodings/cp860.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp861.pyi b/stdlib/encodings/cp861.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp861.pyi +++ b/stdlib/encodings/cp861.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp862.pyi b/stdlib/encodings/cp862.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp862.pyi +++ b/stdlib/encodings/cp862.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp863.pyi b/stdlib/encodings/cp863.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp863.pyi +++ b/stdlib/encodings/cp863.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp864.pyi b/stdlib/encodings/cp864.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp864.pyi +++ b/stdlib/encodings/cp864.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp865.pyi b/stdlib/encodings/cp865.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp865.pyi +++ b/stdlib/encodings/cp865.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp866.pyi b/stdlib/encodings/cp866.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp866.pyi +++ b/stdlib/encodings/cp866.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp869.pyi b/stdlib/encodings/cp869.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/cp869.pyi +++ b/stdlib/encodings/cp869.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp874.pyi b/stdlib/encodings/cp874.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp874.pyi +++ b/stdlib/encodings/cp874.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/cp875.pyi b/stdlib/encodings/cp875.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/cp875.pyi +++ b/stdlib/encodings/cp875.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/hp_roman8.pyi b/stdlib/encodings/hp_roman8.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/hp_roman8.pyi +++ b/stdlib/encodings/hp_roman8.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_1.pyi b/stdlib/encodings/iso8859_1.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_1.pyi +++ b/stdlib/encodings/iso8859_1.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_10.pyi b/stdlib/encodings/iso8859_10.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_10.pyi +++ b/stdlib/encodings/iso8859_10.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_11.pyi b/stdlib/encodings/iso8859_11.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_11.pyi +++ b/stdlib/encodings/iso8859_11.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_13.pyi b/stdlib/encodings/iso8859_13.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_13.pyi +++ b/stdlib/encodings/iso8859_13.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_14.pyi b/stdlib/encodings/iso8859_14.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_14.pyi +++ b/stdlib/encodings/iso8859_14.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_15.pyi b/stdlib/encodings/iso8859_15.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_15.pyi +++ b/stdlib/encodings/iso8859_15.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_16.pyi b/stdlib/encodings/iso8859_16.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_16.pyi +++ b/stdlib/encodings/iso8859_16.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_2.pyi b/stdlib/encodings/iso8859_2.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_2.pyi +++ b/stdlib/encodings/iso8859_2.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_3.pyi b/stdlib/encodings/iso8859_3.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_3.pyi +++ b/stdlib/encodings/iso8859_3.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_4.pyi b/stdlib/encodings/iso8859_4.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_4.pyi +++ b/stdlib/encodings/iso8859_4.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_5.pyi b/stdlib/encodings/iso8859_5.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_5.pyi +++ b/stdlib/encodings/iso8859_5.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_6.pyi b/stdlib/encodings/iso8859_6.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_6.pyi +++ b/stdlib/encodings/iso8859_6.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_7.pyi b/stdlib/encodings/iso8859_7.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_7.pyi +++ b/stdlib/encodings/iso8859_7.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_8.pyi b/stdlib/encodings/iso8859_8.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_8.pyi +++ b/stdlib/encodings/iso8859_8.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/iso8859_9.pyi b/stdlib/encodings/iso8859_9.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/iso8859_9.pyi +++ b/stdlib/encodings/iso8859_9.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/koi8_r.pyi b/stdlib/encodings/koi8_r.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/koi8_r.pyi +++ b/stdlib/encodings/koi8_r.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/koi8_t.pyi b/stdlib/encodings/koi8_t.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/koi8_t.pyi +++ b/stdlib/encodings/koi8_t.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/koi8_u.pyi b/stdlib/encodings/koi8_u.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/koi8_u.pyi +++ b/stdlib/encodings/koi8_u.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/kz1048.pyi b/stdlib/encodings/kz1048.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/kz1048.pyi +++ b/stdlib/encodings/kz1048.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_arabic.pyi b/stdlib/encodings/mac_arabic.pyi index 42781b489298..d2aa4e779744 100644 --- a/stdlib/encodings/mac_arabic.pyi +++ b/stdlib/encodings/mac_arabic.pyi @@ -3,7 +3,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_croatian.pyi b/stdlib/encodings/mac_croatian.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_croatian.pyi +++ b/stdlib/encodings/mac_croatian.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_cyrillic.pyi b/stdlib/encodings/mac_cyrillic.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_cyrillic.pyi +++ b/stdlib/encodings/mac_cyrillic.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_farsi.pyi b/stdlib/encodings/mac_farsi.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_farsi.pyi +++ b/stdlib/encodings/mac_farsi.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_greek.pyi b/stdlib/encodings/mac_greek.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_greek.pyi +++ b/stdlib/encodings/mac_greek.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_iceland.pyi b/stdlib/encodings/mac_iceland.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_iceland.pyi +++ b/stdlib/encodings/mac_iceland.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_latin2.pyi b/stdlib/encodings/mac_latin2.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_latin2.pyi +++ b/stdlib/encodings/mac_latin2.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_roman.pyi b/stdlib/encodings/mac_roman.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_roman.pyi +++ b/stdlib/encodings/mac_roman.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_romanian.pyi b/stdlib/encodings/mac_romanian.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_romanian.pyi +++ b/stdlib/encodings/mac_romanian.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/mac_turkish.pyi b/stdlib/encodings/mac_turkish.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/mac_turkish.pyi +++ b/stdlib/encodings/mac_turkish.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/palmos.pyi b/stdlib/encodings/palmos.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/palmos.pyi +++ b/stdlib/encodings/palmos.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/ptcp154.pyi b/stdlib/encodings/ptcp154.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/ptcp154.pyi +++ b/stdlib/encodings/ptcp154.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stdlib/encodings/punycode.pyi b/stdlib/encodings/punycode.pyi index eb99e667b416..7612464f7d56 100644 --- a/stdlib/encodings/punycode.pyi +++ b/stdlib/encodings/punycode.pyi @@ -1,4 +1,5 @@ import codecs +from _typeshed import ReadableBuffer from typing import Literal def segregate(str: str) -> tuple[bytes, list[int]]: ... @@ -19,13 +20,13 @@ def punycode_decode(text: memoryview | bytes | bytearray | str, errors: str) -> class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: memoryview | bytes | bytearray | str, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: str | ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... class IncrementalDecoder(codecs.IncrementalDecoder): - def decode(self, input: memoryview | bytes | bytearray | str, final: bool = False) -> str: ... # type: ignore[override] + def decode(self, input: str | ReadableBuffer, final: bool = False) -> str: ... class StreamWriter(Codec, codecs.StreamWriter): ... class StreamReader(Codec, codecs.StreamReader): ... diff --git a/stdlib/encodings/tis_620.pyi b/stdlib/encodings/tis_620.pyi index f62195662ce9..2924e73c3543 100644 --- a/stdlib/encodings/tis_620.pyi +++ b/stdlib/encodings/tis_620.pyi @@ -4,7 +4,7 @@ from _typeshed import ReadableBuffer class Codec(codecs.Codec): def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input: str, final: bool = False) -> bytes: ... diff --git a/stubs/pyserial/serial/tools/hexlify_codec.pyi b/stubs/pyserial/serial/tools/hexlify_codec.pyi index 10e43143ee48..c30a145508e0 100644 --- a/stubs/pyserial/serial/tools/hexlify_codec.pyi +++ b/stubs/pyserial/serial/tools/hexlify_codec.pyi @@ -8,7 +8,7 @@ def hex_decode(data: bytes, errors: str = "strict") -> tuple[str, int]: ... class Codec(codecs.Codec): def encode(self, data: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, data: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, data: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): state: int diff --git a/stubs/webencodings/webencodings/custom.pyi b/stubs/webencodings/webencodings/custom.pyi index d74042a7cf47..ee185bab2918 100644 --- a/stubs/webencodings/webencodings/custom.pyi +++ b/stubs/webencodings/webencodings/custom.pyi @@ -7,7 +7,7 @@ class Codec(codecs.Codec): encoding_table: ClassVar[_EncodeCharMap | Literal[""] | None] decoding_table: ClassVar[_DecodeCharMap | None] def encode(self, input: str, errors: str = "strict") -> tuple[bytes, int]: ... - def decode(self, input: bytes, errors: str = "strict") -> tuple[str, int]: ... + def decode(self, input: ReadableBuffer, errors: str = "strict") -> tuple[str, int]: ... class IncrementalEncoder(codecs.IncrementalEncoder): encoding_table: ClassVar[_EncodeCharMap | Literal[""] | None]