Introducing Flask-Sockets
kennethreitz.org
kennethreitz.org
However, based on my testing, in its current state it's nowhere near ready for production. There are some serious bugs relating to memory leaks, improperly closing stale sockets, and deployment on Gunicorn with # workers > 1 is not currently possible. (And in practice I don't think you would want to deploy on anything besides Gunicorn.) The project also seems to be somewhat inactive, there are a lot of open critical issues and there hasn't been any real activity in the last 6 months or so.
At this point I am considering removing the library and using a straight websocket implementation with a simpler protocol instead.
(You should definitely have a look at uWSGI.)
(The last time I looked, which was a few months ago anyway, uWSGI support for gevent/websockets wasn't very robust.)
Not to discredit the attempt to make gevent-websocket more accessible, but there's nothing really new here. Here's an example of using gevent-websocket with flask without this library: https://gist.github.com/lrvick/1185629
This also doesn't require the use of Gevent, like using gevent-websockets directly does. Anything that inserts `wsgi.websocket` into the WSGI environ will suffice here.
Also, how is it better than Tornado web sockets?
https://github.com/surfly/gevent/issues/38
You can check Python 3 support for major packages at: https://python3wos.appspot.com
Unfortunately this relies on gevent and gevent does not work on py3.