[Twisted-Python] [Twisted - Python] Telnet client & keeping connection alive

MichaƂ Tyde ajchos at wp.pl
Wed Aug 10 07:17:03 MDT 2005


First i want to thank all people that responsed for my ealier questions.
I have done a progress in my project.I am a green in Twisted/Python, and
network programming in general.
Now I got a working telnet client. I have got two kind of telnet
servers. First one (after succesfuly login) keeps connection even if I
don't send a command to him. Second one disconnect me every 30 sec., if
I don't send command to him. So I want to create a thread (after
connection to the server) that will send to him a "pwd" command. I want
this thread to run constantly and sending every 20 sec "pwd" command. Of
course in the meantime i want to get responses for my enother commands.
Is this the best idea? Where should I do this (in protocol or in
factory)? Maybe there is another solution.
Where can I find some tutorials with code examples about threads in
Python/Twisted? Please send me a link with working pattern of telnet
client in Twisted. I have look for this kind of code but i couldn't find
anything. I don't know if my code is good (he works, but sometimes I
dont know why). Maybe some suggestions.
Thank You in advance for answers.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: stara.py
Type: text/x-python
Size: 2971 bytes
Desc: not available
URL: </pipermail/twisted-python/attachments/20050810/a8734d50/attachment-0002.py>


More information about the Twisted-Python mailing list