def send_mail(self):
threading.Thread(target=self._send_mail, name='send-mail-real').start()
while not self.__event.is_set():
with self.__cond:
self.__cond.wait()
if 'mail' in self.message.type:
try:
self.__mail_queue.put(self.message, timeout=1)
except Full:
logging.error('mail queue is full')
评论列表
文章目录