Commit 9806f701 authored by Benjamin Graillot's avatar Benjamin Graillot


parent 30d587ba
import json
import threading
import config
class Source:
def __init__(self, name, address=None, args=(), kwargs={}): = name.casefold()
self.address = address.casefold()
self.thread = threading.Thread(target=self.loop, args=args, kwargs=kwargs)
def push_update(self, page, message):
with open(config.socket_path, 'w') as fifo:
fifo.write(json.dumps({'source':, 'page': page, 'message': message}, separators=(',', ':')))
def loop(self, *args, **kwargs):
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment