From f6012124b718da122e8df0d62e2cc803993e170e Mon Sep 17 00:00:00 2001 From: ishaan-jaff Date: Wed, 10 Jan 2024 13:17:34 +0530 Subject: [PATCH] (fix) test for captured caplog --- litellm/tests/test_router_debug_logs.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/litellm/tests/test_router_debug_logs.py b/litellm/tests/test_router_debug_logs.py index 54c2248ca..e850dce63 100644 --- a/litellm/tests/test_router_debug_logs.py +++ b/litellm/tests/test_router_debug_logs.py @@ -65,6 +65,13 @@ def test_async_fallbacks(caplog): asyncio.run(_make_request()) captured_logs = [rec.message for rec in caplog.records] + + # on circle ci the captured logs get some async task exception logs - filter them out + "Task exception was never retrieved" + captured_logs = [ + log for log in captured_logs if "Task exception was never retrieved" not in log + ] + print("\n Captured caplog records - ", captured_logs) # Define the expected log messages