mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-08 13:04:46 +08:00
stdlib: add argument default values (#9501)
This commit is contained in:
@@ -23,7 +23,12 @@ class Filter(BaseFilter):
|
||||
def filename_pattern(self) -> str: ...
|
||||
all_frames: bool
|
||||
def __init__(
|
||||
self, inclusive: bool, filename_pattern: str, lineno: int | None = ..., all_frames: bool = ..., domain: int | None = ...
|
||||
self,
|
||||
inclusive: bool,
|
||||
filename_pattern: str,
|
||||
lineno: int | None = None,
|
||||
all_frames: bool = False,
|
||||
domain: int | None = None,
|
||||
) -> None: ...
|
||||
|
||||
class Statistic:
|
||||
@@ -80,11 +85,11 @@ class Traceback(Sequence[Frame]):
|
||||
if sys.version_info >= (3, 9):
|
||||
@property
|
||||
def total_nframe(self) -> int | None: ...
|
||||
def __init__(self, frames: Sequence[_FrameTuple], total_nframe: int | None = ...) -> None: ...
|
||||
def __init__(self, frames: Sequence[_FrameTuple], total_nframe: int | None = None) -> None: ...
|
||||
else:
|
||||
def __init__(self, frames: Sequence[_FrameTuple]) -> None: ...
|
||||
|
||||
def format(self, limit: int | None = ..., most_recent_first: bool = ...) -> list[str]: ...
|
||||
def format(self, limit: int | None = None, most_recent_first: bool = False) -> list[str]: ...
|
||||
@overload
|
||||
def __getitem__(self, index: SupportsIndex) -> Frame: ...
|
||||
@overload
|
||||
@@ -104,11 +109,11 @@ class Traceback(Sequence[Frame]):
|
||||
|
||||
class Snapshot:
|
||||
def __init__(self, traces: Sequence[_TraceTuple], traceback_limit: int) -> None: ...
|
||||
def compare_to(self, old_snapshot: Snapshot, key_type: str, cumulative: bool = ...) -> list[StatisticDiff]: ...
|
||||
def compare_to(self, old_snapshot: Snapshot, key_type: str, cumulative: bool = False) -> list[StatisticDiff]: ...
|
||||
def dump(self, filename: str) -> None: ...
|
||||
def filter_traces(self, filters: Sequence[DomainFilter | Filter]) -> Snapshot: ...
|
||||
@staticmethod
|
||||
def load(filename: str) -> Snapshot: ...
|
||||
def statistics(self, key_type: str, cumulative: bool = ...) -> list[Statistic]: ...
|
||||
def statistics(self, key_type: str, cumulative: bool = False) -> list[Statistic]: ...
|
||||
traceback_limit: int
|
||||
traces: Sequence[Trace]
|
||||
|
||||
Reference in New Issue
Block a user