Skip to content

Commit e96d146

Browse files
Peter Uittenbroekpuittenbroek
authored andcommitted
fix mypy issues
1 parent c2d47f1 commit e96d146

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

sentry_sdk/utils.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,7 @@ def iter_stacks(tb):
469469
def get_lines_from_file(
470470
filename, # type: str
471471
lineno, # type: int
472-
max_length, # type: int
472+
max_length=None, # type: Optional[int]
473473
loader=None, # type: Optional[Any]
474474
module=None, # type: Optional[str]
475475
):
@@ -614,7 +614,7 @@ def serialize_frame(
614614
include_source_context=True,
615615
max_string_length=None,
616616
):
617-
# type: (FrameType, Optional[int], bool, bool) -> Dict[str, Any]
617+
# type: (FrameType, Optional[int], bool, bool, Optional[int]) -> Dict[str, Any]
618618
f_code = getattr(frame, "f_code", None)
619619
if not f_code:
620620
abs_path = None
@@ -650,9 +650,11 @@ def serialize_frame(
650650

651651

652652
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]
654656
):
655-
# type: (bool, bool) -> Any
657+
# type: (...) -> Dict[str, Any]
656658
__tracebackhide__ = True
657659
frames = []
658660

0 commit comments

Comments
 (0)