back age
Browse files
lightrag/kg/postgres_impl.py
CHANGED
@@ -173,6 +173,11 @@ class PostgreSQLDB:
|
|
173 |
):
|
174 |
try:
|
175 |
async with self.pool.acquire() as connection: # type: ignore
|
|
|
|
|
|
|
|
|
|
|
176 |
if data is None:
|
177 |
await connection.execute(sql) # type: ignore
|
178 |
else:
|
|
|
173 |
):
|
174 |
try:
|
175 |
async with self.pool.acquire() as connection: # type: ignore
|
176 |
+
if with_age and graph_name:
|
177 |
+
await self.configure_age(connection, graph_name) # type: ignore
|
178 |
+
elif with_age and not graph_name:
|
179 |
+
raise ValueError("Graph name is required when with_age is True")
|
180 |
+
|
181 |
if data is None:
|
182 |
await connection.execute(sql) # type: ignore
|
183 |
else:
|