diff options
| author | bwarsaw | 2001-11-20 16:48:27 +0000 |
|---|---|---|
| committer | bwarsaw | 2001-11-20 16:48:27 +0000 |
| commit | 02f20e29ffc40af0a90329327a8cab52759093da (patch) | |
| tree | 3da97a1745c729232d5f937b8bd47cb0096487c2 /scripts | |
| parent | 828f217842b5455661340bce013c07e3fd996f7c (diff) | |
| download | mailman-02f20e29ffc40af0a90329327a8cab52759093da.tar.gz mailman-02f20e29ffc40af0a90329327a8cab52759093da.tar.zst mailman-02f20e29ffc40af0a90329327a8cab52759093da.zip | |
Support for VERP deliveries.
process(): Don't hardcode the envelope sender to the -admin address.
First off, we're directing bounces to the -bounces address. Second,
if we're VERPing, we'll be calculating the envelope sender
individually for each recipient in the deliver() function.
When VERPIng, set the envsender local variable to a tuple containing
some pre-calculated information needed by deliver(). Specifically it
will contain the split mailbox and domain of the list's -bounces
address.
Also, when VERPing, each chunk will contain exactly one recipient, so
use a list comprehension to calculate this (it's actually a list of
lists where the inner list has one item).
We'll also pass the envsender local variable to both
threaded_deliver() and deliver().
To make VERP delivery slightly more efficient, every thread gets its
own connection to the MTA. So we create an smtplib.SMTP instance once
but do not connect it until we actually get to deliver() -- and there
we have to use a kludge to determine whether we're connected or not.
deliver() will re-use the connection to the MTA to do the
conn.sendmail() calls.
pre_deliver(): Add the conn argument.
threaded_deliver(): Create one smtplib.SMTP instance for each thread.
Be sure to close the connection when the thread is finished.
deliver(): Add the conn argument. Craft the VERP envelope sender as
described above. Make sure the MTA connection is connect()'ed.
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions
