Flask-socketio messages not being received when sent from worker script to web script #1974
-
Duplicate of question posted on StackOverflow earlier today I am using flask-socketio to implement websockets on my Flask app. An intensive function runs on a worker script and is supposed to emit a message to the websocket when it is complete. This message should then be received by the client and used to update the display. The trouble I'm having is that messages sent from the worker script do not get received by the client. The same messages sent from within the Flask app are received. I assume the problem is that the two different scripts have different websocket connections; how do I make them talk to each other? worker.py (running outside of Flask app) - this does not get received by client
main.py (running inside Flask app) - this does get received by client
Front end
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Answer on Stack Overflow: https://stackoverflow.com/a/76045858/904393 |
Beta Was this translation helpful? Give feedback.
Answer on Stack Overflow: https://stackoverflow.com/a/76045858/904393