From 49da3a2d747fc3ce00ef9675629473e1d2b26c99 Mon Sep 17 00:00:00 2001 From: msinkec Date: Thu, 27 May 2021 08:58:32 +0200 Subject: [PATCH] temp disable imap copying to sent folder because it blocks sometimes --- portal/base.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/portal/base.py b/portal/base.py index 78f41d0..68f5d36 100644 --- a/portal/base.py +++ b/portal/base.py @@ -193,10 +193,10 @@ class UploadHandler: server.sendmail(message['From'], message['To'], text) # Save copy of sent mail in Sent mailbox - imap = imaplib.IMAP4_SSL(self.config['MAIL_HOST'], self.config['IMAP_PORT']) - imap.login(self.config['MAIL_LOGIN'], self.config['MAIL_PASS']) - imap.append('Sent', '\\Seen', imaplib.Time2Internaldate(time.time()), text.encode('utf8')) - imap.logout() + #imap = imaplib.IMAP4_SSL(self.config['MAIL_HOST'], self.config['IMAP_PORT']) + #imap.login(self.config['MAIL_LOGIN'], self.config['MAIL_PASS']) + #imap.append('Sent', '\\Seen', imaplib.Time2Internaldate(time.time()), text.encode('utf8')) + #imap.logout() except Exception: traceback.print_exc()