class_docstr: Send messages to queue.
  
  :meta private:
class_docstr_tok: ["Send","messages","to","queue",".",":","meta","private",":"]
code: def emit(self, record: logging.LogRecord) -> None:
      # There is no need to call `prepare` because queue is in same process.
      try:
          self.enqueue(record)
      except asyncio.CancelledError:
          raise
      except Exception:
          self.handleError(record)
  
imports: from __future__ import annotations
  import asyncio
  import logging
  from contextvars import ContextVar
  from copy import copy
  from logging.handlers import QueueHandler
  from typing import TYPE_CHECKING
label_desc: Use image node_id 1 for calling the LocalQueueHandler obj's underlying member method code with example usage: obj.emit(record) without return types