[Mailman-Users] Re: No footer

Jim Tittsler jwt at OnJapan.net
Thu Jun 24 05:14:53 CEST 2004

On Sat, Jun 19, 2004 at 09:24:52PM +0200, Stefan Waidele jun. wrote:
> Brad Knowles wrote:
> >At 12:17 PM -0400 2004-06-17, Anita Lewis wrote:
> >
> >> I don't have root privilege on the server.  The person who does made
> >> the new list. 
> I am that person. Hi I'm Stefan :)
> You suggested (in a PM to Anita, I think) that we add more logging into 
> .../Mailman/Handlers/Decorate.py like this:
> syslog('error', 'can't add footer because xxx')

Ah.  I think *I* was *that* person.

> Since we were not able to use SMTPDirect.py because the server only 
> accepts authenticated smtp-connections, which do not seem to work with 
> SMTPDirect.py

Ah!  Python's smtplib module grew support for SMTP auth in
version 2.2.  If you need only a single user/password, you
could embed it in SMTPdirect:

--- /usr/local/src/mailman-2.1.5/Mailman/Handlers/SMTPDirect.py	2004-01-23 08:02:07.000000000 +0900
+++ SMTPDirect.py	2004-06-24 11:55:29.420208168 +0900
@@ -61,6 +61,7 @@
     def __connect(self):
         self.__conn = smtplib.SMTP()
         self.__conn.connect(mm_cfg.SMTPHOST, mm_cfg.SMTPPORT)
+        self.__conn.login('user', 'password')
         self.__numsessions = mm_cfg.SMTP_MAX_SESSIONS_PER_CONNECTION
     def sendmail(self, envsender, recips, msgtext):

--- /usr/local/src/mailman-2.1.5/Mailman/Handlers/SMTPDirect.py

Cleaner alternatives might be to:
 - if the user/passord are the same for all the lists, put them
   in your mm_cfg.py and reference them here
 - add them to the affected list's MailList object (using
   bin/withlist) and reference them here (guarded by an
   'if' to make sure they exist)

> So, against the warning in Sendmail.py, we are using that
> handler for sending mail. I have inserted the call to
> Decorate.py I saw in SMTPDirect.py where I thought it would be
> appropriate, but with no success.

It does seem a bug that Sendmail.py isn't doing the
decoration...  I think most people are using SMTPDirect to
inject their messages into their mail systems.

Jim Tittsler             http://www.OnJapan.net/      GPG: 0x01159DB6
Python Starship          http://Starship.Python.net/
Ringo MUG Tokyo          http://www.ringo.net/rss.html

More information about the Mailman-Users mailing list