You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My Flask app can quite happily emit socket messages from within the @socketio.on() decorator, and when I run the app bare locally (with socketio.run(app)) I can also use socketio.emit('my response', {'data': 'Server generated event'}) as in the example code. However, when I use gunicorn as my server (gunicorn --worker-class socketio.sgunicorn.GeventSocketIOWorker mymodule:app), my @socketio.on()-decorated emit() works fine but my server-generated events fail silently. I have tried various namespaces for them, including no mentioned namespace, namespace="", and namespace="/test". I'm running the app with debug=False. What else can I try?
The text was updated successfully, but these errors were encountered:
My Flask app can quite happily emit socket messages from within the @socketio.on() decorator, and when I run the app bare locally (with
socketio.run(app)
) I can also usesocketio.emit('my response', {'data': 'Server generated event'})
as in the example code. However, when I use gunicorn as my server (gunicorn --worker-class socketio.sgunicorn.GeventSocketIOWorker mymodule:app
), my @socketio.on()-decorated emit() works fine but my server-generated events fail silently. I have tried various namespaces for them, including no mentioned namespace,namespace=""
, andnamespace="/test"
. I'm running the app with debug=False. What else can I try?The text was updated successfully, but these errors were encountered: