summaryrefslogtreecommitdiff
path: root/src/mailman/queue/outgoing.py
diff options
context:
space:
mode:
authorBarry Warsaw2009-11-03 22:29:18 -0500
committerBarry Warsaw2009-11-03 22:29:18 -0500
commitd93c9f447482e14e0385854b661200553db661a1 (patch)
treece84655ee4fe3d39af99f4e37b0ae7228d0bf5f6 /src/mailman/queue/outgoing.py
parent83773bbce02e9083f3f427537b9e5bf135f52cd9 (diff)
downloadmailman-d93c9f447482e14e0385854b661200553db661a1.tar.gz
mailman-d93c9f447482e14e0385854b661200553db661a1.tar.zst
mailman-d93c9f447482e14e0385854b661200553db661a1.zip
Diffstat (limited to 'src/mailman/queue/outgoing.py')
-rw-r--r--src/mailman/queue/outgoing.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/mailman/queue/outgoing.py b/src/mailman/queue/outgoing.py
index 7776b1b54..b1adbe411 100644
--- a/src/mailman/queue/outgoing.py
+++ b/src/mailman/queue/outgoing.py
@@ -26,7 +26,7 @@ from datetime import datetime
from lazr.config import as_timedelta
from mailman.config import config
-from mailman.core import errors
+from mailman.interfaces.mta import SomeRecipientsFailed
from mailman.queue import Runner
from mailman.queue.bounce import BounceMixin
from mailman.utilities.modules import find_name
@@ -81,9 +81,9 @@ class OutgoingRunner(Runner, BounceMixin):
config.mta.host, port)
self._logged = True
return True
- except errors.SomeRecipientsFailed, e:
+ except SomeRecipientsFailed as error:
# Handle local rejects of probe messages differently.
- if msgdata.get('probe_token') and e.permfailures:
+ if msgdata.get('probe_token') and error.permanent_failures:
self._probe_bounce(mlist, msgdata['probe_token'])
else:
# Delivery failed at SMTP time for some or all of the
@@ -95,15 +95,15 @@ class OutgoingRunner(Runner, BounceMixin):
# this is what's sent to the user in the probe message. Maybe
# we should craft a bounce-like message containing information
# about the permanent SMTP failure?
- if e.permfailures:
- self._queue_bounces(mlist.fqdn_listname, e.permfailures,
- msg)
+ if error.permanent_failures:
+ self._queue_bounces(
+ mlist.fqdn_listname, error.permanent_failures, msg)
# Move temporary failures to the qfiles/retry queue which will
# occasionally move them back here for another shot at
# delivery.
- if e.tempfailures:
+ if error.temporary_failures:
now = datetime.now()
- recips = e.tempfailures
+ recips = error.temporary_failures
last_recip_count = msgdata.get('last_recip_count', 0)
deliver_until = msgdata.get('deliver_until', now)
if len(recips) == last_recip_count: