File tree Expand file tree Collapse file tree 1 file changed +0
-17
lines changed
Expand file tree Collapse file tree 1 file changed +0
-17
lines changed Original file line number Diff line number Diff line change @@ -509,23 +509,6 @@ async def source(self, message):
509509 async def stackTrace (self , message ):
510510 """Handle a stack trace message."""
511511 reply = await self ._forward_message (message )
512- # The stackFrames array can have the following content:
513- # { frames from the notebook}
514- # ...
515- # { 'id': xxx, 'name': '<module>', ... } <= this is the first frame of the code from the notebook
516- # { frames from ipykernel }
517- # ...
518- # {'id': yyy, 'name': '<module>', ... } <= this is the first frame of ipykernel code
519- # or only the frames from the notebook.
520- # We want to remove all the frames from ipykernel when they are present.
521- try :
522- sf_list = reply ["body" ]["stackFrames" ]
523- module_idx = len (sf_list ) - next (
524- i for i , v in enumerate (reversed (sf_list ), 1 ) if v ["name" ] == "<module>" and i != 1
525- )
526- reply ["body" ]["stackFrames" ] = reply ["body" ]["stackFrames" ][: module_idx + 1 ]
527- except StopIteration :
528- pass
529512 return reply
530513
531514 def accept_variable (self , variable_name ):
You can’t perform that action at this time.
0 commit comments