code: def background_scan(content_dir):
      
      observer = watchdog.observers.Observer()
      observer.schedule(IndexWatchdog(content_dir),
                        content_dir, recursive=True)
      logging.info("Watching %s for changes", content_dir)
      observer.start()
docs: Start background scanning a directory for changes