Small fix for pkg_resources StrPath (#12015)

This commit is contained in:
Avasam
2024-05-23 12:13:53 -04:00
committed by GitHub
parent 76a42727ab
commit c11fc20651

View File

@@ -384,7 +384,7 @@ class Distribution(NullProvider):
) -> None: ...
@classmethod
def from_location(
cls, location: str, basename: str, metadata: _MetadataType = None, *, precedence: int = 3
cls, location: str, basename: StrPath, metadata: _MetadataType = None, *, precedence: int = 3
) -> Distribution: ...
@property
def hashcmp(self) -> tuple[parse_version, int, str, str | None, str, str]: ...
@@ -405,7 +405,7 @@ class Distribution(NullProvider):
def activate(self, path: list[str] | None = None, replace: bool = False) -> None: ...
def egg_name(self) -> str: ... # type: ignore[override] # supertype's egg_name is a variable, not a method
@classmethod
def from_filename(cls, filename: StrOrBytesPath, metadata: _MetadataType = None, *, precedence: int = 3) -> Distribution: ...
def from_filename(cls, filename: StrPath, metadata: _MetadataType = None, *, precedence: int = 3) -> Distribution: ...
def as_requirement(self) -> Requirement: ...
def load_entry_point(self, group: str, name: str) -> _ResolvedEntryPoint: ...
@overload