docstr: Check for new events every second.
docstr_tok: ["Check","for","new","events","every","second","."]
code: def _thread_body(self) -> None:
      """Check for new events every second."""
      shutdown_time: Optional[float] = None
      while True:
          self._process_events()
          if self._shutdown.is_set():
              now = time.time()
              if not shutdown_time:
                  shutdown_time = now + SHUTDOWN_DELAY
              elif now > shutdown_time:
                  break
          time.sleep(1)
  
imports: import glob
  import logging
  import os
  import queue
  import socket
  import sys
  import threading
  import time
  from typing import TYPE_CHECKING, Any, Dict, List, Optional
  import wandb
  from wandb import util
  from wandb.sdk.interface.interface import GlobStr
  from wandb.sdk.lib import filesystem
  from wandb.viz import CustomChart
  from .None import run
label_desc: Use image node_id 7 for calling the TBDirWatcher obj's underlying member method code with example usage: obj._thread_body() without return types