ConnectionResetError: [Errno 104] Connection reset by peer

October 28, 2018 2.6k views
Python Nginx Ubuntu 16.04

ERROR:flask.app:Exception on / [GET]
Oct 28 11:35:26 pythongram gunicorn[1518]: Traceback (most recent call last):
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/urllib3/connectionpool.py”, line 600, in urlopen
Oct 28 11:35:26 pythongram gunicorn[1518]: chunked=chunked)
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/urllib3/connectionpool.py”, line 384, in makerequest
Oct 28 11:35:26 pythongram gunicorn[1518]: six.raisefrom(e, None)
Oct 28 11:35:26 pythongram gunicorn[1518]: File “<string>”, line 2, in raise
from
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/urllib3/connectionpool.py”, line 380, in makerequest
Oct 28 11:35:26 pythongram gunicorn[1518]: httplibresponse = conn.getresponse()
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/usr/lib/python3.5/http/client.py”, line 1197, in getresponse
Oct 28 11:35:26 pythongram gunicorn[1518]: response.begin()
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/usr/lib/python3.5/http/client.py”, line 297, in begin
Oct 28 11:35:26 pythongram gunicorn[1518]: version, status, reason = self.
readstatus()
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/usr/lib/python3.5/http/client.py”, line 258, in _read
status
Oct 28 11:35:26 pythongram gunicorn[1518]: line = str(self.fp.readline(MAXLINE + 1), “iso-8859-1”)
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/usr/lib/python3.5/socket.py”, line 575, in readinto
Oct 28 11:35:26 pythongram gunicorn[1518]: return self.
sock.recvinto(b)
Oct 28 11:35:26 pythongram gunicorn[1518]: ConnectionResetError: [Errno 104] Connection reset by peer
Oct 28 11:35:26 pythongram gunicorn[1518]: During handling of the above exception, another exception occurred:
Oct 28 11:35:26 pythongram gunicorn[1518]: Traceback (most recent call last):
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/flask/app.py”, line 2292, in wsgi
app
Oct 28 11:35:26 pythongram gunicorn[1518]: response = self.fulldispatchrequest()
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/flask/app.py”, line 1815, in fulldispatchrequest
Oct 28 11:35:26 pythongram gunicorn[1518]: rv = self.handleuserexception(e)
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/flask/app.py”, line 1718, in handleuserexception
Oct 28 11:35:26 pythongram gunicorn[1518]: reraise(exctype, excvalue, tb)
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/flask/compat.py”, line 35, in reraise
Oct 28 11:35:26 pythongram gunicorn[1518]: raise value
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/flask/app.py”, line 1813, in full
dispatchrequest
Oct 28 11:35:26 pythongram gunicorn[1518]: rv = self.dispatch
request()
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/venv/lib/python3.5/site-packages/flask/app.py”, line 1799, in dispatchrequest
Oct 28 11:35:26 pythongram gunicorn[1518]: return self.view
functions[rule.endpoint](**req.viewargs)
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/hg.py”, line 10, in hello
Oct 28 11:35:26 pythongram gunicorn[1518]: test
like()
Oct 28 11:35:26 pythongram gunicorn[1518]: File “/home/apps/hg/hg.py”, line 19, in test_like

Be the first one to answer this question.