batch debugging

This commit is contained in:
Gary Caldwell 2025-04-26 10:46:08 -07:00
parent 29141d2bae
commit 5e529e1462
2 changed files with 3 additions and 0 deletions

View file

@ -1422,6 +1422,7 @@ Model Info:
print(f"slack url before log_queue {slack_webhook_url}")
print(f"slack payload {payload}")
print(f"slack batchsize {self.batch_size}")
if isinstance(slack_webhook_url, list):
for url in slack_webhook_url:
self.log_queue.append(

View file

@ -42,6 +42,7 @@ class CustomBatchLogger(CustomLogger):
await self.flush_queue()
async def flush_queue(self):
print(f"flushing queue: {self.flush_lock}")
if self.flush_lock is None:
return
@ -50,6 +51,7 @@ class CustomBatchLogger(CustomLogger):
verbose_logger.debug(
"CustomLogger: Flushing batch of %s events", len(self.log_queue)
)
print("calling send_batch")
await self.async_send_batch()
self.log_queue.clear()
self.last_flush_time = time.time()