I have been trying to make use of the builtin medusa ftp_server classes
and after struggling a while came across the strange practice some
internal zope developer has of dynamically changing classes at runtime.

ie in ZServer.FTPServer I came across 

from medusa.ftp_server import ftp_channel, ftp_server, recv_channel
# Override ftp server receive channel reponse mechanism 
# XXX hack alert, this should probably be redone in a more OO way.

def handle_close (self):
    self.readable=lambda :0 # don't call close again


which makes it virtually impossible to re-use medusa's ftp_server in a
reasonable way. The comment says it all.

The real problem is that ftp_channel uses a method make_recv_channel
which uses a global class recv_channel and the recv_channel class has a
particular method which zope wants to override. How ought this kind of
situation to be handled more cleanly?
Robin Becker

Zope-Dev maillist  -  [EMAIL PROTECTED]
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to