mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-08 04:54:47 +08:00
mimetypes.guess_type() accepts PathLikes in 3.8+ (#6716)
This commit is contained in:
@@ -28,7 +28,10 @@ class MimeTypes:
|
||||
types_map_inv: tuple[dict[str, str], dict[str, str]]
|
||||
def __init__(self, filenames: tuple[str, ...] = ..., strict: bool = ...) -> None: ...
|
||||
def guess_extension(self, type: str, strict: bool = ...) -> str | None: ...
|
||||
def guess_type(self, url: str, strict: bool = ...) -> tuple[str | None, str | None]: ...
|
||||
if sys.version_info >= (3, 8):
|
||||
def guess_type(self, url: StrPath, strict: bool = ...) -> tuple[str | None, str | None]: ...
|
||||
else:
|
||||
def guess_type(self, url: str, strict: bool = ...) -> tuple[str | None, str | None]: ...
|
||||
def guess_all_extensions(self, type: str, strict: bool = ...) -> list[str]: ...
|
||||
def read(self, filename: str, strict: bool = ...) -> None: ...
|
||||
def readfp(self, fp: IO[str], strict: bool = ...) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user