mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-10 05:51:52 +08:00
platform, tarfile, io: Python 3.13 updates (#12056)
This commit is contained in:
@@ -119,7 +119,6 @@ importlib.resources.open_text
|
||||
importlib.resources.path
|
||||
importlib.resources.read_binary
|
||||
importlib.resources.read_text
|
||||
io.IOBase._checkClosed
|
||||
mailbox.Maildir.add_flag
|
||||
mailbox.Maildir.get_flags
|
||||
mailbox.Maildir.get_info
|
||||
@@ -139,10 +138,6 @@ pdb.Pdb.do_exceptions
|
||||
pdb.Pdb.interaction
|
||||
pdb.Pdb.message
|
||||
pdb.Pdb.user_opcode
|
||||
platform.AndroidVer
|
||||
platform.IOSVersionInfo
|
||||
platform.android_ver
|
||||
platform.ios_ver
|
||||
pstats.FunctionProfile.__replace__
|
||||
pstats.StatsProfile.__replace__
|
||||
pydoc.pager
|
||||
@@ -157,7 +152,6 @@ sqlite3.dbapi2.Connection.iterdump
|
||||
sre_compile.SRE_FLAG_TEMPLATE
|
||||
sre_constants.SRE_FLAG_TEMPLATE
|
||||
sre_parse.SRE_FLAG_TEMPLATE
|
||||
tarfile.TarFile.__init__
|
||||
threading.stack_size
|
||||
tkinter.Misc.after_info
|
||||
tkinter.Misc.busy
|
||||
|
||||
@@ -75,7 +75,7 @@ class IOBase(metaclass=abc.ABCMeta):
|
||||
def __del__(self) -> None: ...
|
||||
@property
|
||||
def closed(self) -> bool: ...
|
||||
def _checkClosed(self, msg: str | None = ...) -> None: ... # undocumented
|
||||
def _checkClosed(self) -> None: ... # undocumented
|
||||
|
||||
class RawIOBase(IOBase):
|
||||
def readall(self) -> bytes: ...
|
||||
|
||||
@@ -40,3 +40,28 @@ def platform(aliased: bool = ..., terse: bool = ...) -> str: ...
|
||||
|
||||
if sys.version_info >= (3, 10):
|
||||
def freedesktop_os_release() -> dict[str, str]: ...
|
||||
|
||||
if sys.version_info >= (3, 13):
|
||||
class AndroidVer(NamedTuple):
|
||||
release: str
|
||||
api_level: int
|
||||
manufacturer: str
|
||||
model: str
|
||||
device: str
|
||||
is_emulator: bool
|
||||
|
||||
class IOSVersionInfo(NamedTuple):
|
||||
system: str
|
||||
release: str
|
||||
model: str
|
||||
is_simulator: bool
|
||||
|
||||
def android_ver(
|
||||
release: str = "",
|
||||
api_level: int = 0,
|
||||
manufacturer: str = "",
|
||||
model: str = "",
|
||||
device: str = "",
|
||||
is_emulator: bool = False,
|
||||
) -> AndroidVer: ...
|
||||
def ios_ver(system: str = "", release: str = "", model: str = "", is_simulator: bool = False) -> IOSVersionInfo: ...
|
||||
|
||||
@@ -142,22 +142,43 @@ class TarFile:
|
||||
errorlevel: int | None
|
||||
offset: int # undocumented
|
||||
extraction_filter: _FilterFunction | None
|
||||
def __init__(
|
||||
self,
|
||||
name: StrOrBytesPath | None = None,
|
||||
mode: Literal["r", "a", "w", "x"] = "r",
|
||||
fileobj: _Fileobj | None = None,
|
||||
format: int | None = None,
|
||||
tarinfo: type[TarInfo] | None = None,
|
||||
dereference: bool | None = None,
|
||||
ignore_zeros: bool | None = None,
|
||||
encoding: str | None = None,
|
||||
errors: str = "surrogateescape",
|
||||
pax_headers: Mapping[str, str] | None = None,
|
||||
debug: int | None = None,
|
||||
errorlevel: int | None = None,
|
||||
copybufsize: int | None = None, # undocumented
|
||||
) -> None: ...
|
||||
if sys.version_info >= (3, 13):
|
||||
stream: bool
|
||||
def __init__(
|
||||
self,
|
||||
name: StrOrBytesPath | None = None,
|
||||
mode: Literal["r", "a", "w", "x"] = "r",
|
||||
fileobj: _Fileobj | None = None,
|
||||
format: int | None = None,
|
||||
tarinfo: type[TarInfo] | None = None,
|
||||
dereference: bool | None = None,
|
||||
ignore_zeros: bool | None = None,
|
||||
encoding: str | None = None,
|
||||
errors: str = "surrogateescape",
|
||||
pax_headers: Mapping[str, str] | None = None,
|
||||
debug: int | None = None,
|
||||
errorlevel: int | None = None,
|
||||
copybufsize: int | None = None, # undocumented
|
||||
stream: bool = False,
|
||||
) -> None: ...
|
||||
else:
|
||||
def __init__(
|
||||
self,
|
||||
name: StrOrBytesPath | None = None,
|
||||
mode: Literal["r", "a", "w", "x"] = "r",
|
||||
fileobj: _Fileobj | None = None,
|
||||
format: int | None = None,
|
||||
tarinfo: type[TarInfo] | None = None,
|
||||
dereference: bool | None = None,
|
||||
ignore_zeros: bool | None = None,
|
||||
encoding: str | None = None,
|
||||
errors: str = "surrogateescape",
|
||||
pax_headers: Mapping[str, str] | None = None,
|
||||
debug: int | None = None,
|
||||
errorlevel: int | None = None,
|
||||
copybufsize: int | None = None, # undocumented
|
||||
) -> None: ...
|
||||
|
||||
def __enter__(self) -> Self: ...
|
||||
def __exit__(
|
||||
self, type: type[BaseException] | None, value: BaseException | None, traceback: TracebackType | None
|
||||
|
||||
Reference in New Issue
Block a user