summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbwarsaw2003-08-18 02:56:07 +0000
committerbwarsaw2003-08-18 02:56:07 +0000
commitaa36f578e9146afba2504db07770538817927919 (patch)
treebd132eb35f5b157dd9b35e13d5a781fa103cafcf
parent716d523b06863c216ae82f28fb840d68cd9a29c2 (diff)
downloadmailman-aa36f578e9146afba2504db07770538817927919.tar.gz
mailman-aa36f578e9146afba2504db07770538817927919.tar.zst
mailman-aa36f578e9146afba2504db07770538817927919.zip
-rw-r--r--cron/disabled20
1 files changed, 15 insertions, 5 deletions
diff --git a/cron/disabled b/cron/disabled
index dcf05f250..75972e55c 100644
--- a/cron/disabled
+++ b/cron/disabled
@@ -1,19 +1,19 @@
#! @PYTHON@
#
-# Copyright (C) 2001,2002 by the Free Software Foundation, Inc.
+# Copyright (C) 2001-2003 by the Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
-#
+#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-#
+#
# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
+# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
"""Process disabled members, recommended once per day.
@@ -73,6 +73,7 @@ from Mailman import Utils
from Mailman import MailList
from Mailman import Pending
from Mailman import MemberAdaptor
+from Mailman import Errors
from Mailman.Bouncer import _BounceInfo
from Mailman.Logging.Syslog import syslog
from Mailman.i18n import _
@@ -198,7 +199,16 @@ def main():
for member in notify:
syslog('bounce', 'Notifying disabled member %s for list: %s',
member, mlist.internal_name())
- mlist.sendNextNotification(member)
+ try:
+ mlist.sendNextNotification(member)
+ except Errors.NotAMemberError:
+ # There must have been some problem with the data we have
+ # on this member. Most likely it's that they don't have a
+ # password assigned. Log this and delete the member.
+ syslog('bounce',
+ 'NotAMemberError when sending disabled notice: %s',
+ member)
+ mlist.ApprovedDeleteMember(member, 'cron/disabled')
mlist.Save()
finally:
mlist.Unlock()