Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

Ensure stackFrame and levels in stack request are optional #77

Merged
merged 2 commits into from
Feb 15, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions ptvsd/wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -518,9 +518,9 @@ def on_threads(self, request, args):
def on_stackTrace(self, request, args):
# TODO: docstring
tid = int(args['threadId'])
startFrame = int(args['startFrame'])
levels = int(args['levels'])

startFrame = int(args['startFrame']) if 'startFrame' in args else 0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

int(args.get('startFrame', 0))?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lol, will do

levels = int(args['levels']) if 'levels' in args else 0
''
tid = self.thread_map.to_pydevd(tid)
with self.stack_traces_lock:
xframes = self.stack_traces[tid]
Expand Down