Skip to content

Commit

Permalink
If the arguments.breakpoints is not set, default to an empty list
Browse files Browse the repository at this point in the history
  • Loading branch information
unknownv2 authored and fabioz committed Oct 5, 2024
1 parent 31f7645 commit 781bf41
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion _pydevd_bundle/pydevd_process_net_command_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -765,6 +765,7 @@ def on_setfunctionbreakpoints_request(self, py_db, request):
expression = None

breakpoints_set = []
arguments.breakpoints = arguments.breakpoints or []
for bp in arguments.breakpoints:
hit_condition = self._get_hit_condition_expression(bp.get("hitCondition"))
condition = bp.get("condition")
Expand Down Expand Up @@ -805,7 +806,7 @@ def on_setbreakpoints_request(self, py_db, request):
btype = "jinja2-line"

breakpoints_set = []

arguments.breakpoints = arguments.breakpoints or []
for source_breakpoint in arguments.breakpoints:
source_breakpoint = SourceBreakpoint(**source_breakpoint)
line = source_breakpoint.line
Expand Down

0 comments on commit 781bf41

Please sign in to comment.