like below fixes the issue Interesting problem. Unfortunately session access in a Socket.IO event is not bi-directional. You can get the contents of the session, but you cannot make modifications, since the entire Socket.IO session occurs within a single WebSocket request, making it impossible to send an HTTP response with the session updates.
Python heroku configure procfile gunicorn + gevent for socket.io chat app | RuntimeError: You need to use the gevent-web
Does that help The error is correct, you need to use the gevent-websocket webserver and not the native gevent web server that comes with gunicorn. It seems you are searching for answers all over the place. I would suggest that you use the Flask-SocketIO documentation as the ultimate source of truth, as I keep that updated.
I wish this helpful for you The portion of the docs that you quoted refers to the async_mode argument, and how it is set by default. You are setting async_mode='threading', so that disables the automatic selection of an async mode. Remove the argument, and then you'll get eventlet or gevent, depending on what you have installed.