From 62883e86fb43974bf939d3779a862692e2c3e1d3 Mon Sep 17 00:00:00 2001 From: Kastan Day Date: Tue, 7 Nov 2023 18:13:13 +0100 Subject: [PATCH] adding proper error logging to image ingest --- ai_ta_backend/vector_database.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ai_ta_backend/vector_database.py b/ai_ta_backend/vector_database.py index a969c9c1..d8692fac 100644 --- a/ai_ta_backend/vector_database.py +++ b/ai_ta_backend/vector_database.py @@ -434,7 +434,7 @@ def _ingest_single_image(self, s3_path: str, course_name: str, **kwargs) -> str: self.split_and_upload(texts=texts, metadatas=metadatas) return "Success" except Exception as e: - print(f"Image ingest error (png/jpg) ERROR {e}") + print(f"❌❌ Error in (png/jpg ingest): `{inspect.currentframe().f_code.co_name}`: {e}\nTraceback:\n", traceback.print_exc()) return f"Error: {e}" def _ingest_single_csv(self, s3_path: str, course_name: str, **kwargs) -> str: