Re: [Twisted-Python] ftpclient connection lost callback

2013-09-05 Thread Peter Ryan
Thanks. So is the idiomatic approach for this with something like the FTPClient to subclass it and override connectionLost? FTPClientBasic clears up queued commands when this happens (which I assume I still want it to do). To me it seems a little overbearing to have to subclass the ftpclient just

Re: [Twisted-Python] ftpclient connection lost callback

2013-09-05 Thread exarkun
On 06:48 pm, pe...@peterryan.net wrote: Thanks. So is the idiomatic approach for this with something like the FTPClient to subclass it and override connectionLost? FTPClientBasic clears up queued commands when this happens (which I assume I still want it to do). Is it idiomatic? I don't kn

[Twisted-Python] ftpclient connection lost callback

2013-09-05 Thread Peter Ryan
I am writing a simple ftp client which I am trying to dispose of. Right now I send a quit command: (the ftp_client reference is a FTPClient built with a ClientCreator) deferred = ftp_client.quit() And I register a callback: def quitSent(response): print "quit acknowledged...connected?", ftp_

Re: [Twisted-Python] ftpclient connection lost callback

2013-09-05 Thread exarkun
On 05:49 pm, pe...@peterryan.net wrote: I am writing a simple ftp client which I am trying to dispose of. Right now I send a quit command: (the ftp_client reference is a FTPClient built with a ClientCreator) deferred = ftp_client.quit() And I register a callback: def quitSent(response): pr