@@ -469,7 +469,7 @@ def iter_stacks(tb):
469
469
def get_lines_from_file (
470
470
filename , # type: str
471
471
lineno , # type: int
472
- max_length , # type: int
472
+ max_length = None , # type: Optional[ int]
473
473
loader = None , # type: Optional[Any]
474
474
module = None , # type: Optional[str]
475
475
):
@@ -614,7 +614,7 @@ def serialize_frame(
614
614
include_source_context = True ,
615
615
max_string_length = None ,
616
616
):
617
- # type: (FrameType, Optional[int], bool, bool) -> Dict[str, Any]
617
+ # type: (FrameType, Optional[int], bool, bool, Optional[int] ) -> Dict[str, Any]
618
618
f_code = getattr (frame , "f_code" , None )
619
619
if not f_code :
620
620
abs_path = None
@@ -650,9 +650,11 @@ def serialize_frame(
650
650
651
651
652
652
def current_stacktrace (
653
- include_local_variables = True , include_source_context = True , max_string_length = None
653
+ include_local_variables = True , # type: bool
654
+ include_source_context = True , # type: bool
655
+ max_string_length = None , # type: Optional[int]
654
656
):
655
- # type: (bool, bool ) -> Any
657
+ # type: (... ) -> Dict[str, Any]
656
658
__tracebackhide__ = True
657
659
frames = []
658
660
0 commit comments