Enable Ruff PLC (Pylint Convention) (#13306)

This commit is contained in:
Avasam
2025-03-03 15:39:40 +01:00
committed by GitHub
parent 738cc5046a
commit 6d6e858e63
17 changed files with 173 additions and 153 deletions
+13 -13
View File
@@ -22,31 +22,31 @@ class Callpoint:
def from_tb(cls, tb: TracebackType) -> Self: ...
def tb_frame_str(self) -> str: ...
_CallpointT = TypeVar("_CallpointT", bound=Callpoint, covariant=True, default=Callpoint)
_CallpointT_co = TypeVar("_CallpointT_co", bound=Callpoint, covariant=True, default=Callpoint)
class TracebackInfo(Generic[_CallpointT]):
callpoint_type: type[_CallpointT]
frames: list[_CallpointT]
def __init__(self, frames: list[_CallpointT]) -> None: ...
class TracebackInfo(Generic[_CallpointT_co]):
callpoint_type: type[_CallpointT_co]
frames: list[_CallpointT_co]
def __init__(self, frames: list[_CallpointT_co]) -> None: ...
@classmethod
def from_frame(cls, frame: FrameType | None = None, level: int = 1, limit: int | None = None) -> Self: ...
@classmethod
def from_traceback(cls, tb: TracebackType | None = None, limit: int | None = None) -> Self: ...
@classmethod
def from_dict(cls, d: Mapping[Literal["frames"], list[_CallpointT]]) -> Self: ...
def to_dict(self) -> dict[str, list[dict[str, _CallpointT]]]: ...
def from_dict(cls, d: Mapping[Literal["frames"], list[_CallpointT_co]]) -> Self: ...
def to_dict(self) -> dict[str, list[dict[str, _CallpointT_co]]]: ...
def __len__(self) -> int: ...
def __iter__(self) -> Iterator[_CallpointT]: ...
def __iter__(self) -> Iterator[_CallpointT_co]: ...
def get_formatted(self) -> str: ...
_TracebackInfoT = TypeVar("_TracebackInfoT", bound=TracebackInfo, covariant=True, default=TracebackInfo)
_TracebackInfoT_co = TypeVar("_TracebackInfoT_co", bound=TracebackInfo, covariant=True, default=TracebackInfo)
class ExceptionInfo(Generic[_TracebackInfoT]):
tb_info_type: type[_TracebackInfoT]
class ExceptionInfo(Generic[_TracebackInfoT_co]):
tb_info_type: type[_TracebackInfoT_co]
exc_type: str
exc_msg: str
tb_info: _TracebackInfoT
def __init__(self, exc_type: str, exc_msg: str, tb_info: _TracebackInfoT) -> None: ...
tb_info: _TracebackInfoT_co
def __init__(self, exc_type: str, exc_msg: str, tb_info: _TracebackInfoT_co) -> None: ...
@classmethod
def from_exc_info(cls, exc_type: type[BaseException], exc_value: BaseException, traceback: TracebackType) -> Self: ...
@classmethod