mirror of
https://github.com/oxen-io/oxen-pyoxenmq.git
synced 2023-12-13 20:50:34 +01:00
4597f5ca6c
* rename all namespaces so it compiles again
16 lines
284 B
Python
16 lines
284 B
Python
import pyoxenmq
|
|
import time
|
|
|
|
def handle_ping(args):
|
|
print(args)
|
|
return args
|
|
|
|
lmq = pyoxenmq.OxenMQ()
|
|
lmq.listen_plain("ipc:///tmp/lmq.sock")
|
|
lmq.add_anonymous_category("python")
|
|
lmq.add_request_command("python", "ping", handle_ping)
|
|
lmq.start()
|
|
|
|
while True:
|
|
time.sleep(1)
|