dyad
dyad copied to clipboard
Python compatible?
Hi. Is it possible to use Python sockets to contact with C side that uses dyad?
Yes — If you build and run the echo server example, the following python script could be used on the same machine to connect to it:
import socket
s = socket.socket()
s.connect(("localhost", 8000))
s.send("Hello world\n")
print(s.recv(100))
You can write methods in c that are wrapped using the CPython API, therefore you can call those methods straight in python.