code: def emit(self, record):
          
          self.entries.append(self.format(record))
          if len(self.entries) > self.flush_limit and not self.session.auth.renewing:
              self.log_to_api()
              self.entries = []
docs: Emit the log record.