Pamudu13 commited on
Commit
39af9a4
·
verified ·
1 Parent(s): 9a6d59c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -492,7 +492,7 @@ def stream_logs():
492
  while True:
493
  try:
494
  # Get log message from queue, timeout after 1 second
495
- log_message = log_queue.get()
496
  yield f"data: {log_message}\n\n"
497
  except queue.Empty:
498
  # Send a heartbeat to keep the connection alive
 
492
  while True:
493
  try:
494
  # Get log message from queue, timeout after 1 second
495
+ log_message = log_queue.get(timeout=10)
496
  yield f"data: {log_message}\n\n"
497
  except queue.Empty:
498
  # Send a heartbeat to keep the connection alive