[Mailman-Developers] mailman does not work with exim and python 1.5.2

The Dragon De Monsyne dragondm@integral.org
Mon, 26 Apr 1999 11:02:26 -0500 (CDT)


On Sun, 25 Apr 1999, Gergely Madarasz wrote:

> Hello!
> 
> Mailman does not work with exim and python 1.5.2, probably because of the
> esmtp support in python 1.5.2's smtplib. Following is a trace from exim.
> Note that exim gets an ehlo and later a helo which resets it into smtp
> from esmtp. Please forward this to the appropriate python forums :)

	Erf, yes,I should have thrown a warning your folx's way (I'm the 
maintainer of python's smtplib) In 1.5.2 some of the return values of
methods have been changed. Before, some of the methods returned integrer
codes, some string descriptions, and some (code,desc) tuples. Now they
_all_ return tuples (and the exception objects have more meaningful info,
too). I'm in the middle of moving now, so I  don't have access to a news
server that carries c.l.p ATM, and half my equipment is packed. the patch
should be simple In Mailman.Utils.TrySMTPDelivery() there is a few lines
like:

        conn = smtplib.SMTP(mm_cfg.SMTPHOST)
        # Do the EHLO/HELO manually so we can check for DSN support
        if conn.ehlo() >= 400:
            conn.helo()

change it to:

        conn = smtplib.SMTP(mm_cfg.SMTPHOST)
        # Do the EHLO/HELO manually so we can check for DSN support
        if conn.ehlo()[0] >= 400:
            conn.helo()


(This change was considered resonable, as only code using ESMTP would
likely need to call the SMTP command methods, most other code just uses
the sendmail() method, and 1.5.1's smtplib didn't support ESMTP, so 1.5.2
was the 'last chance' to regularize the return values )

	-The Dragon De Monsyne