Closed fabswt closed 9 months ago
Outside of app
, debug
, host
and port
, any arguments that you pass to socketio.run()
are passed to the web server that you are using. Since three different web servers are supported, it would be difficult to support a uniform set of arguments that are internally converted to what each web server needs.
Also consider that Flask's app.run()
is a) not for production use and b) sort of a moving target, as Flask developers routinely add/change/deprecate its arguments. So it isn't a good model to follow for Flask-SocketIO.
Before Flask-WebSocketIO, I was able to start Flask like so:
With Flask-WebSocketIO, I have to start it like so:
Mind
int()
, andssl_context
dropped in favor of certfile/keyfile.int()
, I'd get:TypeError: 'str' object cannot be interpreted as an integer
.ssl_context
, I'd end up withAttributeError: 'tuple' object has no attribute 'wrap_socket'
.Describe the solution you'd like
I would suggest updating the arguments to
socketio.run()
to accept the same asapp.run()
did for ease and comfort.