|
|
|
@ -312,13 +312,12 @@ class Bureau(object):
|
|
|
|
|
poller.register(self._recv, zmq.POLLIN)
|
|
|
|
|
|
|
|
|
|
while True:
|
|
|
|
|
try:
|
|
|
|
|
msgs = dict(poller.poll(500))
|
|
|
|
|
if msgs:
|
|
|
|
|
if msgs.get(self._recv) == zmq.POLLIN:
|
|
|
|
|
msg = self._recv.recv_string(flags=zmq.NOBLOCK)
|
|
|
|
|
else:
|
|
|
|
|
continue
|
|
|
|
|
msgs = dict(poller.poll(500))
|
|
|
|
|
if msgs:
|
|
|
|
|
if msgs.get(self._recv) == zmq.POLLIN:
|
|
|
|
|
msg = self._recv.recv_string(flags=zmq.NOBLOCK)
|
|
|
|
|
else:
|
|
|
|
|
continue
|
|
|
|
|
# msg = self._recv.recv_string(flags=zmq.NOBLOCK)
|
|
|
|
|
#except zmq.ZMQError:
|
|
|
|
|
# time.sleep(0.05) # don't waste CPU
|
|
|
|
|