Skip to content

Commit 48b6a6d

Browse files
authored
Merge pull request #2446 from danielaskdd/fix-postgres
fix(postgres): Add CASCADE to AGE extension creation for automatic dependency resolution
2 parents 607c11c + d6019c8 commit 48b6a6d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lightrag/kg/postgres_impl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ async def configure_vector_extension(connection: asyncpg.Connection) -> None:
383383
async def configure_age_extension(connection: asyncpg.Connection) -> None:
384384
"""Create AGE extension if it doesn't exist for graph operations."""
385385
try:
386-
await connection.execute("CREATE EXTENSION IF NOT EXISTS age") # type: ignore
386+
await connection.execute("CREATE EXTENSION IF NOT EXISTS AGE CASCADE") # type: ignore
387387
logger.info("PostgreSQL, AGE extension enabled")
388388
except Exception as e:
389389
logger.warning(f"Could not create AGE extension: {e}")

0 commit comments

Comments
 (0)