Skip to content

Commit

Permalink
Update eventStreamer.py
Browse files Browse the repository at this point in the history
test fix for Home Assistant dropping connection after few hours.
  • Loading branch information
TRusselo authored Mar 26, 2023
1 parent 455d30c commit b61e871
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion BridgeEmulator/services/eventStreamer.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def streamV2Events():
def generate():
counter = 1000
yield f": hi\n\n"
while counter > 0: # ensure we stop at some point
while True: # ensure we stop at some point
if len(HueObjects.eventstream) > 0:
for index, messages in enumerate(HueObjects.eventstream):
yield f"id: {int(time()) }:{index}\ndata: {json.dumps([messages], separators=(',', ':'))}\n\n"
Expand Down

0 comments on commit b61e871

Please sign in to comment.