[Zope] Fix for lots of MailHost problems!

Soren Roug soren@roug.org
Tue, 25 Jan 2000 10:22:57 +0100


I just applied the patch to Zope 2.1.0 on Digital Unix 4E. Before the patch
<dtml-sendmail> would crash zope, so I had nothing to loose.

After the patch <dtml-sendmail> works as expected.

Michel Pelletier wrote:

> > -----Original Message-----
> > From: Stephen Pitts [mailto:smpitts@midsouth.rr.com]
> >
> > I was having lots of trouble with <dtml-sendmail>, and I investigated
> > the code for MailHost. Instead of using the excellent smtplib module
> > (that ships with Python) to send EMail, the folks at DC
> > decided to write
> > their own, using sockets.
>
> We wrote it before the smtplib module was standard in Python.
>
> > The attatched patch replaces 100+ lines of socket-based code
> > with 2 line
> > calls to smtplib. I think that this will improve the reliability of
> > MailHost dramatically. As a side effect, the timeout and localhost
> > properties of MailHosts are gone.
>
> A 98% code reduction.  Not bad.
>
> > So far, the basic <dtml-sendmail> tag works perfectly.
> > Someone try this
> > out and tell me what you think.
>
> If someone can verify that this works I'll eye it and check it in (send
> it to me directly as a reminder)
>
> -Michel