diff options
| author | bwarsaw | 2002-03-09 17:49:02 +0000 |
|---|---|---|
| committer | bwarsaw | 2002-03-09 17:49:02 +0000 |
| commit | d4bae06d11fc0b412774db6b46bbe4d13cc3fcdd (patch) | |
| tree | 1e0f2a42ffee4b4fbe8c5e081ce24453ee66139d /Mailman/Handlers/ToOutgoing.py | |
| parent | 87e337dfea7873154d18fc7c04473da450abe30a (diff) | |
| download | mailman-d4bae06d11fc0b412774db6b46bbe4d13cc3fcdd.tar.gz mailman-d4bae06d11fc0b412774db6b46bbe4d13cc3fcdd.tar.zst mailman-d4bae06d11fc0b412774db6b46bbe4d13cc3fcdd.zip | |
Diffstat (limited to 'Mailman/Handlers/ToOutgoing.py')
| -rw-r--r-- | Mailman/Handlers/ToOutgoing.py | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/Mailman/Handlers/ToOutgoing.py b/Mailman/Handlers/ToOutgoing.py index 45f23ff51..b9b4c7f15 100644 --- a/Mailman/Handlers/ToOutgoing.py +++ b/Mailman/Handlers/ToOutgoing.py @@ -27,17 +27,23 @@ from Mailman.Queue.sbcache import get_switchboard def process(mlist, msg, msgdata): - # Do VERP calculation for non-personalized interval delivery. BAW: We - # can't do this in OutgoingRunner.py (where it was originally) because - # that runner loads the list unlocked and we can't have it re-load the - # list state for every cycle through its mainloop. interval = mm_cfg.VERP_DELIVERY_INTERVAL - # If occasional VERPing is turned on, and we haven't't already made a - # VERPing decision... - if interval > 0 and not msgdata.has_key('verp'): - if interval == 1: - # VERP every time + # Should we VERP this message? If personalization is enabled for this + # list and VERP_PERSONALIZED_DELIVERIES is true, then yes we VERP it. + # Also, if personalization is /not/ enabled, but VERP_DELIVERY_INTERVAL is + # set (and we've hit this interval), then again, this message should be + # VERPed. Otherwise, no. + if mlist.personalize: + if mm_cfg.VERP_PERSONALIZED_DELIVERIES: msgdata['verp'] = 1 + elif interval == 0: + # Never VERP + pass + elif interval == 1: + # VERP every time + msgdata['verp'] = 1 + else: + # VERP every `inteval' number of times msgdata['verp'] = not int(mlist.post_id) % interval # And now drop the message in qfiles/out outq = get_switchboard(mm_cfg.OUTQUEUE_DIR) |
