diff --git a/install_gadget.py b/install_gadget.py index ab9e1af..1e9e4d4 100755 --- a/install_gadget.py +++ b/install_gadget.py @@ -37,7 +37,7 @@ import functools import time try: - from io import BytesIO ## for Python 3 + from io import BytesIO # for Python 3 except ImportError: from BytesIO import BytesIO diff --git a/python3/vimspector/stack_trace.py b/python3/vimspector/stack_trace.py index 74bac68..bc150f4 100644 --- a/python3/vimspector/stack_trace.py +++ b/python3/vimspector/stack_trace.py @@ -169,11 +169,11 @@ class StackTraceView( object ): def _JumpToFrame( self, frame ): def do_jump(): - if 'line' in frame and frame[ 'line' ]: + if 'line' in frame and frame[ 'line' ] > 0: self._currentFrame = frame return self._session.SetCurrentFrame( self._currentFrame ) - source = frame[ 'source' ] + source = frame.get( 'source', {} ) if source.get( 'sourceReference', 0 ) > 0: def handle_resolved_source( resolved_source ): frame[ 'source' ] = resolved_source