summaryrefslogtreecommitdiff
path: root/Mailman/Bouncer.py
diff options
context:
space:
mode:
authorbwarsaw2001-07-18 22:14:17 +0000
committerbwarsaw2001-07-18 22:14:17 +0000
commitc25b14b37811e636d957fa1cc101620560395e48 (patch)
treef1428137ef7674e989857fd43ab8c11fb518544a /Mailman/Bouncer.py
parent2bd68751c1e6c8820923d254a6f50901f87a057a (diff)
downloadmailman-c25b14b37811e636d957fa1cc101620560395e48.tar.gz
mailman-c25b14b37811e636d957fa1cc101620560395e48.tar.zst
mailman-c25b14b37811e636d957fa1cc101620560395e48.zip
Diffstat (limited to 'Mailman/Bouncer.py')
-rw-r--r--Mailman/Bouncer.py40
1 files changed, 5 insertions, 35 deletions
diff --git a/Mailman/Bouncer.py b/Mailman/Bouncer.py
index 0a6f44559..743df5921 100644
--- a/Mailman/Bouncer.py
+++ b/Mailman/Bouncer.py
@@ -61,36 +61,6 @@ class Bouncer:
self.max_posts_between_bounces = \
mm_cfg.DEFAULT_MAX_POSTS_BETWEEN_BOUNCES
- def GetConfigInfo(self):
- return [
- _('''Policies regarding systematic processing of bounce messages,
- to help automate recognition and handling of defunct
- addresses.'''),
-
- ('bounce_processing', mm_cfg.Toggle, (_('No'), _('Yes')), 0,
- _('Try to figure out error messages automatically?')),
-
- ('minimum_removal_date', mm_cfg.Number, 3, 0,
- _('''Minimum number of days an address has been non-fatally bad
- before we take action''')),
-
- ('minimum_post_count_before_bounce_action', mm_cfg.Number, 3, 0,
- _('''Minimum number of posts to the list since members first
- bounce before we consider removing them from the list''')),
-
- ('max_posts_between_bounces', mm_cfg.Number, 3, 0,
- _('''Maximum number of messages your list gets in an hour. (Yes,
- bounce detection finds this info useful)''')),
-
- ('automatic_bounce_action', mm_cfg.Radio,
- (_("Do nothing"),
- _("Disable and notify me"),
- _("Disable and DON'T notify me"),
- _("Remove and notify me")),
- 0,
- _("Action when critical or excessive bounces are detected."))
- ]
-
def ClearBounceInfo(self, email):
email = email.lower()
if self.bounce_info.has_key(email):
@@ -278,19 +248,19 @@ Bad admin recipient: %s''', self.internal_name(), addr)
Returning success and notification status.
"""
- if not self.IsMember(addr):
+ if not self.isMember(addr):
reason = _('User not found.')
syslog('bounce', '%s: NOT disabled %s: %s',
self.real_name, addr, reason)
return reason, 1
try:
- if self.GetUserOption(addr, mm_cfg.DisableDelivery):
+ if self.getMemberOption(addr, mm_cfg.DisableDelivery):
# No need to send out notification if they're already disabled.
syslog('bounce', '%s: already disabled %s' %
self.real_name, addr)
return 1, 0
else:
- self.SetUserOption(addr, mm_cfg.DisableDelivery, 1)
+ self.setMemberOption(addr, mm_cfg.DisableDelivery, 1)
syslog('bounce', '%s: disabled %s', self.real_name, addr)
self.Save()
return 1, 1
@@ -305,13 +275,13 @@ Bad admin recipient: %s''', self.internal_name(), addr)
"""Unsubscribe user with bouncing address.
Returning success and notification status."""
- if not self.IsMember(addr):
+ if not self.isMember(addr):
reason = _('User not found.')
syslog('bounce', '%s: NOT removed %s: %s',
self.real_name, addr, reason)
return reason, 1
try:
- self.DeleteMember(addr, "bouncing addr")
+ self.ApprovedDeleteMember(addr, "bouncing addr")
syslog('bounce', '%s: removed %s', self.real_name, addr)
self.Save()
return 1, 1