[Twisted-Python] How to setup a ftpserver, ftpclient?

Andrew Bennetts andrew-twisted at puzzling.org
Mon Apr 8 22:55:14 EDT 2002


On Mon, Apr 08, 2002 at 10:20:06PM -0400, Michael Bacarella wrote:
> On Tue, Apr 09, 2002 at 11:22:47AM +1000, Andrew Bennetts wrote:
> > More pressingly, the FTP server and client need to be refactored to
> > reuse some code.  They are currently two completely seperate code bases
> > with zero reuse :(
> 
> How much code could they share that hasn't already been implemented
> in the rest of Twisted?

Good question.  Probably not a huge amount.  The FTPFileListingProtocol
could probably be taught to write as well as read; and perhaps the
opening and connecting of data connections could be shared.  The data
connections, conceptually at least, are symmetrical.  And I intend to
implement file uploading in the client soon, so data really will flow
both ways.

As for the rest of it, probably not much.  But I'd like to at least try
to see what can be done before trying to build on it much further, when
it will be even harder to do.

-Andrew.





More information about the Twisted-Python mailing list