fix: hide duckdb table not found error log (#3026)
This commit is contained in:
parent
77786d904c
commit
d71356bc16
1 changed files with 14 additions and 3 deletions
|
|
@ -24,7 +24,10 @@ def migrate_messages_from_monitor_service_to_database(session: Session) -> bool:
|
||||||
monitor_service = get_monitor_service()
|
monitor_service = get_monitor_service()
|
||||||
messages_df = monitor_service.get_messages()
|
messages_df = monitor_service.get_messages()
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.error(f"Error retrieving messages from monitor service: {e}")
|
if "Table with name messages does not exist" in str(e):
|
||||||
|
logger.debug(f"Error retrieving messages from monitor service: {e}")
|
||||||
|
else:
|
||||||
|
logger.warning(f"Error retrieving messages from monitor service: {e}")
|
||||||
return False
|
return False
|
||||||
|
|
||||||
if messages_df.empty:
|
if messages_df.empty:
|
||||||
|
|
@ -153,8 +156,16 @@ class TableResults:
|
||||||
|
|
||||||
|
|
||||||
def migrate_transactions_from_monitor_service_to_database(session: Session) -> None:
|
def migrate_transactions_from_monitor_service_to_database(session: Session) -> None:
|
||||||
monitor_service = get_monitor_service()
|
try:
|
||||||
batch = monitor_service.get_transactions()
|
monitor_service = get_monitor_service()
|
||||||
|
batch = monitor_service.get_transactions()
|
||||||
|
except Exception as e:
|
||||||
|
if "Table with name transactions does not exist" in str(e):
|
||||||
|
logger.debug(f"Error retrieving transactions from monitor service: {e}")
|
||||||
|
else:
|
||||||
|
logger.warning(f"Error retrieving transactions from monitor service: {e}")
|
||||||
|
return
|
||||||
|
|
||||||
if not batch:
|
if not batch:
|
||||||
logger.debug("No transactions to migrate.")
|
logger.debug("No transactions to migrate.")
|
||||||
return
|
return
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue