summaryrefslogtreecommitdiff
path: root/mailman/queue/outgoing.py
diff options
context:
space:
mode:
authorBarry Warsaw2008-03-30 00:06:07 -0400
committerBarry Warsaw2008-03-30 00:06:07 -0400
commit7f440dc39489b32257c35f15ee6f27d90a197cf5 (patch)
treea4aaec013ee63253b78cfeb3518e78b1df424a91 /mailman/queue/outgoing.py
parenteecf4b29f2642f30b22ee978fa50d8713bec1a48 (diff)
downloadmailman-7f440dc39489b32257c35f15ee6f27d90a197cf5.tar.gz
mailman-7f440dc39489b32257c35f15ee6f27d90a197cf5.tar.zst
mailman-7f440dc39489b32257c35f15ee6f27d90a197cf5.zip
Diffstat (limited to 'mailman/queue/outgoing.py')
-rw-r--r--mailman/queue/outgoing.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/mailman/queue/outgoing.py b/mailman/queue/outgoing.py
index 838d7d137..4c067b8c0 100644
--- a/mailman/queue/outgoing.py
+++ b/mailman/queue/outgoing.py
@@ -20,10 +20,10 @@
import os
import sys
import copy
-import time
import email
import socket
import logging
+import datetime
from mailman import Errors
from mailman import Message
@@ -57,7 +57,7 @@ class OutgoingRunner(Runner, BounceMixin):
def _dispose(self, mlist, msg, msgdata):
# See if we should retry delivery of this message again.
deliver_after = msgdata.get('deliver_after', 0)
- if time.time() < deliver_after:
+ if datetime.datetime.now() < deliver_after:
return True
# Make sure we have the most up-to-date state
try:
@@ -102,7 +102,7 @@ class OutgoingRunner(Runner, BounceMixin):
# occasionally move them back here for another shot at
# delivery.
if e.tempfailures:
- now = time.time()
+ now = datetime.datetime.now()
recips = e.tempfailures
last_recip_count = msgdata.get('last_recip_count', 0)
deliver_until = msgdata.get('deliver_until', now)