verification of zmq solution working remotely

Signed-off-by: Arthur Lu <learthurgo@gmail.com>

Former-commit-id: 41fb81cfac
This commit is contained in:
Arthur Lu 2021-10-15 06:20:05 +00:00
parent 6cd092da37
commit 6bcb3cbff4

View File

@ -160,6 +160,7 @@ import sys
import time import time
import traceback import traceback
import warnings import warnings
import zmq
from interface import splash, log, ERR, INF, stdout, stderr from interface import splash, log, ERR, INF, stdout, stderr
from data import get_previous_time, pull_new_tba_matches, set_current_time, load_match, push_match, load_pit, push_pit, get_database_config, set_database_config, check_new_database_matches from data import get_previous_time, pull_new_tba_matches, set_current_time, load_match, push_match, load_pit, push_pit, get_database_config, set_database_config, check_new_database_matches
@ -313,8 +314,6 @@ def main(send, verbose = False, profile = False, debug = False):
send(stdout, INF, "closed threads and database client") send(stdout, INF, "closed threads and database client")
send(stdout, INF, "finished all tasks in " + str(time.time() - loop_start) + " seconds, looping") send(stdout, INF, "finished all tasks in " + str(time.time() - loop_start) + " seconds, looping")
raise Exception("boop")
if profile: if profile:
return 0 # return instead of break to avoid sys.exit return 0 # return instead of break to avoid sys.exit
@ -548,8 +547,6 @@ def start(pid_path, verbose = False, profile = False, debug = False):
stderr = f stderr = f
): ):
import zmq
context = zmq.Context() context = zmq.Context()
socket = context.socket(zmq.PUB) socket = context.socket(zmq.PUB)
socket.bind("tcp://*:5678") socket.bind("tcp://*:5678")