summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBlackEagle <ike.devolder@gmail.com>2019-07-06 16:18:21 +0200
committerBlackEagle <ike.devolder@gmail.com>2019-07-06 16:18:21 +0200
commit23824cafb9a70773fcabcb862bf2fd0f144135d2 (patch)
treeff175515125428ac7a399ee84ba59a8617880b49
parent1ebaf2fbbb50ee38fa1248faaa4e7fa8ab1ce4a0 (diff)
downloadvdebug-23824cafb9a70773fcabcb862bf2fd0f144135d2.zip
convert status to str first and check if it exists
Then start checking for interactive or stopping/stopped fixes #362 Signed-off-by: BlackEagle <ike.devolder@gmail.com>
-rw-r--r--python3/vdebug/event.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/python3/vdebug/event.py b/python3/vdebug/event.py
index 975bf13..abda356 100644
--- a/python3/vdebug/event.py
+++ b/python3/vdebug/event.py
@@ -258,12 +258,18 @@ class WatchWindowContextChangeEvent(Event):
class RefreshEvent(Event):
def run(self, status):
- if str(status) == "interactive":
+
+ status_str = str(status)
+
+ if not status_str:
+ return
+
+ if status_str == "interactive":
self.ui.error("Debugger engine says it is in interactive mode,"
"which is not supported: closing connection")
log.Log("closing connection because of interactive mode")
self.session.close_connection()
- elif str(status) in ("stopping", "stopped"):
+ elif status_str in ("stopping", "stopped"):
self.ui.set_status("stopped")
self.ui.say("Debugging session has ended")
log.Log("closing connection because status is stopped")