PY-21488 Stopping docker debug process unexpectedly in the very beginning of Python...
authorAlexander Koshevoy <Alexander.Koshevoy@jetbrains.com>
Wed, 16 Nov 2016 18:34:33 +0000 (21:34 +0300)
committerAlexander Koshevoy <Alexander.Koshevoy@jetbrains.com>
Wed, 16 Nov 2016 18:36:13 +0000 (21:36 +0300)
python/pydevSrc/com/jetbrains/python/debugger/pydev/transport/BaseDebuggerReader.java
python/pydevSrc/com/jetbrains/python/debugger/pydev/transport/ClientModeDebuggerTransport.java
python/pydevSrc/com/jetbrains/python/debugger/pydev/transport/ServerModeDebuggerTransport.java

index 7b53407098b994af1847b236e630c180c50cf8e3..4006832f173fe22928fc3daf9e53f2e06d8eceb4 100644 (file)
@@ -54,10 +54,12 @@ public abstract class BaseDebuggerReader extends BaseOutputReader {
     }
     finally {
       close();
-      myDebugger.fireExitEvent();
+      onExit();
     }
   }
 
+  protected abstract void onExit();
+
   protected abstract void onCommunicationError();
 
   @NotNull
index abf46f6fa11443f7a0bf4b841e154db6c14fad9e..c7816252d8376a5a4022259b099529c5e37097bf 100644 (file)
@@ -252,6 +252,14 @@ public class ClientModeDebuggerTransport extends BaseDebuggerTransport {
       start(getClass().getName());
     }
 
+    @Override
+    protected void onExit() {
+      if (myState == State.APPROVED) {
+        getDebugger().fireExitEvent();
+      }
+    }
+
+    @Override
     protected void onCommunicationError() {
       if (myState == State.APPROVED) {
         getDebugger().fireCommunicationError();
index 0224bf59bb3a26bafbf3d7df067cc836ed295da9..ccd7b6349081da159f98885fb16f44cda0c50542 100644 (file)
@@ -114,6 +114,12 @@ public class ServerModeDebuggerTransport extends BaseDebuggerTransport {
       start(getClass().getName());
     }
 
+    @Override
+    protected void onExit() {
+      getDebugger().fireExitEvent();
+    }
+
+    @Override
     protected void onCommunicationError() {getDebugger().fireCommunicationError();}
   }
 }