Revert "Cleanup of code"
This commit is contained in:
@@ -178,10 +178,12 @@ class PostgreSQLDB:
|
||||
asyncpg.exceptions.UniqueViolationError,
|
||||
asyncpg.exceptions.DuplicateTableError,
|
||||
) as e:
|
||||
if not upsert:
|
||||
logger.error(f"PostgreSQL, upsert error: {e}")
|
||||
if upsert:
|
||||
print("Key value duplicate, but upsert succeeded.")
|
||||
else:
|
||||
logger.error(f"Upsert error: {e}")
|
||||
except Exception as e:
|
||||
logger.error(f"PostgreSQL database, sql:{sql}, data:{data}, error:{e}")
|
||||
logger.error(f"PostgreSQL database,\nsql:{sql},\ndata:{data},\nerror:{e}")
|
||||
raise
|
||||
|
||||
|
||||
@@ -1085,6 +1087,9 @@ class PGGraphStorage(BaseGraphStorage):
|
||||
) -> tuple[np.ndarray[Any, Any], list[str]]:
|
||||
raise NotImplementedError
|
||||
|
||||
async def get_all_labels(self) -> list[str]:
|
||||
raise NotImplementedError
|
||||
|
||||
async def get_knowledge_graph(
|
||||
self, node_label: str, max_depth: int = 5
|
||||
) -> KnowledgeGraph:
|
||||
|
Reference in New Issue
Block a user