code: def inject(**params):
  
      
  
      def callback(log_record):
          log_record.extra.update(params)
      return logbook.Processor(callback)
docs: A Logbook processor to inject arbitrary information into log records.
  
      Simply pass in keyword arguments and use as a context manager:
  
          >>> with inject(identifier=str(uuid.uuid4())).applicationbound():
          ...     logger.debug('Something happened')