Here is a common error I get with Flash Waitress web server I am currently testing: (should I go with Gunicon?)
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/waitress/channel.py”, line 118, in handle_write
File “/usr/local/lib/python3.6/site-packages/waitress/channel.py”, line 207, in _flush_some_if_lockable
File “/usr/local/lib/python3.6/site-packages/waitress/channel.py”, line 227, in _flush_some
num_sent = self.send(chunk)
File “/usr/local/lib/python3.6/site-packages/waitress/wasyncore.py”, line 433, in send
result = self.socket.send(data)
TimeoutError: [Errno 110] Connection timed out
I tried to be compliant with LiteSpeed which my hosting provider will support. There are a few ways to do this with:
This commerical Litespeed link should confirm this OpenLiteSpeed should work
This option with LIteSpeed was not possible. I did however, get uswgi server working from this example on my web hosting provider:
Here are some links to consider
Host it on Heroku? https://www.heroku.com/pricing
Good general overview:
I am using Waitress but it seems to time out quite a bit. This above article recommend \s Gunicorn.
Second article to recommend both Gunicorn but use Nginx instead?
How configure Nginx for Flask
Another Gunicorn with Nginx
A warning about databases for Gunicorn
Comparison across other Python web servers
This says Waitress is safe
Pros for Waitress over Gunicorn
Gunicorn vs Waitress https://stackshare.io/stackups/gunicorn-vs-waitress
Overall list of Python production ready servers
Here is an overall overview with example scripts included:
Gunicon is top and Waitress is second. Let me give Gunicorn a shot in a way to eliminate these socket errors.
This appears to be a simple way to setup Gunicon with Nginx
For CentOS, I had to install Development ToolsFACEBOOK ACCOUNT and TWITTER. Don't worry as I don't post stupid cat videos or what I eat!