close

[Solved] Python handling socket.error: [Errno 104] Connection reset by peer

Hello Guys, How are you all? Hope You all Are Fine. Today I get the following error Python handling socket.error: [Errno 104] Connection reset by peer in python. So Here I am Explain to you all the possible solutions here.

Without wasting your time, Let’s start This Article to Solve This Error.

How Python handling socket.error: [Errno 104] Connection reset by peer Error Occurs?

Today I get the following error Python handling socket.error: [Errno 104] Connection reset by peer in python.

How To Solve Python handling socket.error: [Errno 104] Connection reset by peer Error ?

  1. How To Solve Python handling socket.error: [Errno 104] Connection reset by peer Error ?

    To Solve Python handling socket.error: [Errno 104] Connection reset by peer Error I had this exact error when trying to connect to a remote redis instance from python, because I had mistakenly left Fiddler running and it was interfering with the requests.

  2. Python handling socket.error: [Errno 104] Connection reset by peer

    To Solve Python handling socket.error: [Errno 104] Connection reset by peer Error I had this exact error when trying to connect to a remote redis instance from python, because I had mistakenly left Fiddler running and it was interfering with the requests.

Solution 1

It seems that the clients were connected to the server but they encountered with ” [Errno 104] Connection reset by peer” exception when they tried to send data. For the first time, Python raises “[Errno 104] Connection reset by peer” exception, then for the second time and more you would get “[Errno 32] Broken pipe” exception on the client side.

This can mean that the server is up and listening on the port (otherwise, you would get “[Errno 111] Connection refused" exception on the client side“. This also means that the server is crashed before closing the connection since if the connection was closed on the server side before sending data on the client side, the client would encounter with “[Errno 32] Broken pipe” exception.

Solution 2

I had this exact error when trying to connect to a remote redis instance from python, because I had mistakenly left Fiddler running and it was interfering with the requests.

Summery

It’s all About this issue. Hope all solution helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which solution worked for you? Thank You.

Also, Read