More improvements to startup and closedown stability. Remove some hack code

This commit is contained in:
Ben Jackson 2019-02-12 09:01:09 +00:00
commit e006b15100
5 changed files with 80 additions and 54 deletions

View file

@ -37,6 +37,12 @@ class StackTraceView( object ):
self._line_to_frame = {}
self._line_to_thread = {}
# TODO: We really need a proper state model
#
# AWAIT_CONNECTION -- OnServerReady / RequestThreads --> REQUESTING_THREADS
# REQUESTING -- OnGotThreads / RequestScopes --> REQUESTING_SCOPES
#
def GetCurrentThreadId( self ):
return self._currentThread
@ -51,6 +57,9 @@ class StackTraceView( object ):
with utils.ModifiableScratchBuffer( self._buf ):
utils.ClearBuffer( self._buf )
def ConnectionUp( self, connection ):
self._connection = connection
def ConnectionClosed( self ):
self.Clear()
self._connection = None