Skip to content

Commit c79a28f

Browse files
committed
Add type stubs for the wave stdlib module to align with the Python
3.15 beta changes.
1 parent 526a7dd commit c79a28f

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

stdlib/wave.pyi

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import sys
2+
from os import PathLike
23
from _typeshed import ReadableBuffer, Unused
34
from typing import IO, Any, BinaryIO, Final, Literal, NamedTuple, NoReturn, TypeAlias, overload
45
from typing_extensions import Self, deprecated
@@ -7,7 +8,7 @@ __all__ = ["open", "Error", "Wave_read", "Wave_write"]
78
if sys.version_info >= (3, 15):
89
__all__ += ["WAVE_FORMAT_PCM", "WAVE_FORMAT_IEEE_FLOAT", "WAVE_FORMAT_EXTENSIBLE"]
910

10-
_File: TypeAlias = str | IO[bytes]
11+
_File: TypeAlias = str | IO[bytes] | bytes | PathLike[Any]
1112

1213
class Error(Exception): ...
1314

0 commit comments

Comments
 (0)