Error while connecting to email account System

Hi,

I’ve been trying to find a way to stop getting errors for Email account. The credentials are correct. Same thing is working for another site hosted in another server. I’ve already tired removing the account and domain. The errors are given below.

pull_from_email_account

{‘retry’: 0, ‘log’: <function log at 0x7f3dfe05fcf8>, ‘site’: u’something.com’, ‘event’: u’all’, ‘method_name’: u’pull_from_email_account’, ‘method’: <function pull_from_email_account at 0x7f3dfd57aaa0>, ‘user’: u’Administrator’, ‘kwargs’: {‘email_account’: u’System’}, ‘async’: True, ‘job_name’: u’pull_from_email_account|System’}
Traceback (most recent call last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/utils/background_jobs.py”, line 97, in execute_job
method(**kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/doctype/email_account/email_account.py”, line 704, in pull_from_email_account
email_account.receive()
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/doctype/email_account/email_account.py”, line 258, in receive
emails = email_server.get_messages()
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 105, in get_messages
if not self.connect():
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 44, in connect
return self.connect_imap()
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 52, in connect_imap
self.imap = Timed_IMAP4_SSL(self.settings.host, timeout=frappe.conf.get(“pop_timeout”))
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 550, in init
self._super.init(self, *args, **kwargs)
File “/usr/lib/python2.7/imaplib.py”, line 1166, in init
IMAP4.init(self, host, port)
File “/usr/lib/python2.7/imaplib.py”, line 173, in init
self.open(host, port)
File “/usr/lib/python2.7/imaplib.py”, line 1178, in open
self.sslobj = ssl.wrap_socket(self.sock, self.keyfile, self.certfile)
File “/usr/lib/python2.7/ssl.py”, line 933, in wrap_socket
ciphers=ciphers)
File “/usr/lib/python2.7/ssl.py”, line 601, in init
self.do_handshake()
File “/usr/lib/python2.7/ssl.py”, line 830, in do_handshake
self._sslobj.do_handshake()
error: [Errno 104] Connection reset by peer

Error while connecting to email account System

Traceback (most recent call last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/doctype/email_account/email_account.py”, line 251, in receive
email_server = self.get_incoming_server(in_receive=True, email_sync_rule=email_sync_rule)
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/doctype/email_account/email_account.py”, line 163, in get_incoming_server
email_server.connect()
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 44, in connect
return self.connect_imap()
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 52, in connect_imap
self.imap = Timed_IMAP4_SSL(self.settings.host, timeout=frappe.conf.get(“pop_timeout”))
File “/home/frappe/frappe-bench/apps/frappe/frappe/email/receive.py”, line 550, in init
self._super.init(self, *args, **kwargs)
File “/usr/lib/python2.7/imaplib.py”, line 1166, in init
IMAP4.init(self, host, port)
File “/usr/lib/python2.7/imaplib.py”, line 173, in init
self.open(host, port)
File “/usr/lib/python2.7/imaplib.py”, line 1178, in open
self.sslobj = ssl.wrap_socket(self.sock, self.keyfile, self.certfile)
File “/usr/lib/python2.7/ssl.py”, line 933, in wrap_socket
ciphers=ciphers)
File “/usr/lib/python2.7/ssl.py”, line 601, in init
self.do_handshake()
File “/usr/lib/python2.7/ssl.py”, line 830, in do_handshake
self._sslobj.do_handshake()
File “/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/rq/timeouts.py”, line 51, in handle_death_penalty
‘value ({0} seconds)’.format(self._timeout))
JobTimeoutException: Job exceeded maximum timeout value (300 seconds)

I can’t figure out why it’s behaving like this in this server while same account is working fine on another. Help is really appreciated.

1 Like

Still having this issue, error with email but email is working fine outside of erpnext. Was working yesterday when did support ticket test.