diff roundup/roundupdb.py @ 445:208697858c8b

Message author's name appears in From: instead of roundup instance name (which still appears in the Reply-To:) envelope-from is now set to the roundup-admin and not roundup itself so delivery reports aren't sent to roundup (thanks Patrick Ohly)
author Richard Jones <richard@users.sourceforge.net>
date Wed, 12 Dec 2001 21:47:45 +0000
parents 52b5f53d12f3
children 5b422e3bd05d
line wrap: on
line diff
--- a/roundup/roundupdb.py	Wed Dec 12 03:23:14 2001 +0000
+++ b/roundup/roundupdb.py	Wed Dec 12 21:47:45 2001 +0000
@@ -15,7 +15,7 @@
 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
 # 
-# $Id: roundupdb.py,v 1.29 2001-12-11 04:50:49 richard Exp $
+# $Id: roundupdb.py,v 1.30 2001-12-12 21:47:45 richard Exp $
 
 __doc__ = """
 Extending hyperdb with types specific to issue-tracking.
@@ -356,8 +356,7 @@
         writer = MimeWriter.MimeWriter(message)
         writer.addheader('Subject', '[%s%s] %s'%(cn, nodeid, title))
         writer.addheader('To', ', '.join(sendto))
-        writer.addheader('From', '%s <%s>'%(self.INSTANCE_NAME,
-            self.ISSUE_TRACKER_EMAIL))
+        writer.addheader('From', '%s <%s>'%(authname, self.ISSUE_TRACKER_EMAIL))
         writer.addheader('Reply-To', '%s <%s>'%(self.INSTANCE_NAME,
             self.ISSUE_TRACKER_EMAIL))
         writer.addheader('MIME-Version', '1.0')
@@ -399,7 +398,9 @@
         # now try to send the message
         try:
             smtp = smtplib.SMTP(self.MAILHOST)
-            smtp.sendmail(self.ISSUE_TRACKER_EMAIL, sendto, message.getvalue())
+            # send the message as admin so bounces are sent there instead
+            # of to roundup
+            smtp.sendmail(self.ADMIN_EMAIL, sendto, message.getvalue())
         except socket.error, value:
             raise MessageSendError, \
                 "Couldn't send confirmation email: mailhost %s"%value
@@ -491,6 +492,9 @@
 
 #
 # $Log: not supported by cvs2svn $
+# Revision 1.29  2001/12/11 04:50:49  richard
+# fixed the order of the blank line and '-------' line
+#
 # Revision 1.28  2001/12/10 22:20:01  richard
 # Enabled transaction support in the bsddb backend. It uses the anydbm code
 # where possible, only replacing methods where the db is opened (it uses the

Roundup Issue Tracker: http://roundup-tracker.org/