docs: def queuify_logger(logger, queue_handler, queue_listener):
      """Replace logger's handlers with a queue handler while adding existing
      handlers to a queue listener.
  
      This is useful when you want to use a default logging config but then
      optionally add a logger's handlers to a queue during runtime.
  
      Args:
          logger (mixed): Logger instance or string name of logger to queue-ify
              handlers.
          queue_handler (QueueHandler): Instance of a ``QueueHandler``.
          queue_listener (QueueListener): Instance of a ``QueueListener``.
  
      """
      if isinstance(logger, str):
          logger = logging.getLogger(logger)
  
      # Get handlers that aren't being listened for.
      handlers = [handler for handler in logger.handlers
                  if handler not in queue_listener.handlers]
  
      if handlers:
          # The default QueueListener stores handlers as a tuple.
          queue_listener.handlers = \
              tuple(list(queue_listener.handlers) + handlers)
  
      # Remove logger's handlers and replace with single queue handler.
      del logger.handlers[:]
      logger.addHandler(queue_handler)