[Twisted-Python] dataReveived() buffer best practice?

exarkun at twistedmatrix.com exarkun at twistedmatrix.com
Thu Oct 6 17:06:35 EDT 2011

On 04:22 pm, fabian.rothfuchs at googlemail.com wrote:
>Hey there,
>I'm currently implementing a Telnet Client, which is actually talking 
>to a
>Console Server mapping Telnet to an RS232 interface.
>and this is the result:
>drudge:Desktop rothfuchs$ p s12.py
>received: MM
>received: RID:
>I also ran a tcpdump to confirm ­ The opposite server is obviously 
>content to the socket in arbitrary frequencies, ending up in my
>dataReceived() method to get called arbitrarily as well.

This is not so obvious.  Any hop along the route may fragment the data.
>My question: is there any best practice for buffer techniques here?

This question is too vague.  What problem are you trying to solve?


More information about the Twisted-Python mailing list