Python Client + Node Server not working #1243
-
I am trying to create a websocket framework where there is a server running in node connected to a python client. Examples shown below: client
server
When running the client, the connection is established (as in, the 'hi' is logged), but the output of the message from 'new_exchange' is not given. Equally confusing is when I use
The original 'hi' is not logged. I'm not sure where the inconsistency is coming from and what I am missing. Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
For context, when running both the server and python client in debug mode, I get the following statements: from the server, using
from the client, using
|
Beta Was this translation helpful? Give feedback.
-
The You have a few options to address this:
|
Beta Was this translation helpful? Give feedback.
The
emit
method in the Python client does not wait for the data to be transmitted. You are doing your emits and then immediately disconnecting, without giving time to the messages to arrive.You have a few options to address this:
call()
method instead ofemit()
. Thec…