title: How to prevent Flask Server from crashing after flask Exception happened during processing of request from ('x.x.x.x', 12554)
body: <p>Flask server usually crashes after the Exception:</p>
  
  <pre><code>Exception happened during processing of request from ('x.x.x.x', 12554)
  </code></pre>
  
  <p>This exception usually comes when some client make certain request and closes its connection before receiving the response. Meanwhile, server tries writing to the pipe for the response, which fails as connection is already closed by the client. And, the web server crashes.</p>
  
  <p>Is there any way we can catch this exception, and stops the web server from crashing?</p>