X
X
xAockd2015-11-02 23:51:02
Python
xAockd, 2015-11-02 23:51:02

Python, socket error processing request?

Good afternoon, I'm studying python, I raised the site on the hosting, but it started to give an error that I can't make out. What could be the problem?

2015-11-02 21:57:44 +0000] [31789] [ERROR] Socket error processing request.
Traceback (most recent call last):
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/gunicorn/workers/sync.py", line 130, in handle
    self.handle_request(listener, req, client, addr)
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/gunicorn/workers/sync.py", line 187, in handle_request
    six.reraise(exc_info[0], exc_info[1], exc_info[2])
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/gunicorn/workers/sync.py", line 171, in handle_request
    respiter = self.wsgi(environ, resp.start_response)
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/core/handlers/wsgi.py", line 187, in __call__
    response = self.get_response(request)
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/core/handlers/base.py", line 180, in get_response
    'request': request
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/logging/__init__.py", line 1154, in error
    self._log(ERROR, msg, args, **kwargs)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/logging/__init__.py", line 1246, in _log
    self.handle(record)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/logging/__init__.py", line 1256, in handle
    self.callHandlers(record)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/logging/__init__.py", line 1293, in callHandlers
    hdlr.handle(record)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/logging/__init__.py", line 740, in handle
    self.emit(record)
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/utils/log.py", line 129, in emit
    connection=self.connection())
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/core/mail/__init__.py", line 98, in mail_admins
    mail.send(fail_silently=fail_silently)
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/core/mail/message.py", line 283, in send
    return self.get_connection(fail_silently).send_messages([self])
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/core/mail/backends/smtp.py", line 92, in send_messages
    new_conn_created = self.open()
  File "/home/h22923/data/.pythonbrew/venvs/Python-2.7/mysite/lib/python2.7/site-packages/django/core/mail/backends/smtp.py", line 50, in open
    self.connection = connection_class(self.host, self.port, **connection_params)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/smtplib.py", line 239, in __init__
    (code, msg) = self.connect(host, port)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/smtplib.py", line 295, in connect
    self.sock = self._get_socket(host, port, self.timeout)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/smtplib.py", line 273, in _get_socket
    return socket.create_connection((port, host), timeout)
  File "/home/h22923/data/.pythonbrew/pythons/Python-2.7/lib/python2.7/socket.py", line 567, in create_connection
    raise error, msg
error: [Errno 110] Connection timed out

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
nirvimel, 2015-11-03
@xAockd

The error logging system in django is configured to send messages by mail. And the smtp mail server is apparently set incorrectly.
An error occurs somewhere in the django core while processing the request. The text of this error could tell us something. But when trying to log this message, an attempt is made to send it by mail and an attempt to connect to the mail server (which either does not exist or is not a mail server) while waiting for the connection, crashes with a timeout Connection timed out.
Check your django config, are there any addresses like example.com?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question