Hi,<br><br>I was trying this out:<br><br><br>Server code:<br><br>def dataReceived(self, data):<br>    if (args[&quot;cmd&quot;] == &quot;CHECK_IN&quot;):<br>        foo = subprocess.Popen(&#39;python master.py&#39;,shell = True)<br>
        <i># this ACK notifies the client to close the connection</i><br>        self.transport.write( self.create_message(&quot;CHECK_IN&quot;,&quot;ACK&quot;) )<br><br>I use the subprocess call , as I want to avoid threads here, and independently launch my master.py without blocking this code. <br>
I dont aim to have any interaction with the master.py once it is launched<br><br>Now, I see unpredictable behaviour here..<br>I have been trying many times, but the subprocess call does not happen everytime !<br>The connection is closed by the client without the master getting launched in some cases.<br>
<br>How does the transport.write behave in such cases.. Do you people see a structural problem here.. Or adding some small delay of 2 sec before transport.write might help?<br><br>Regards<br>Naman<br><br><br><br><br><br>