fix: Resolve issue with sqlite on Ubuntu24.04
This commit is contained in:
parent
3dced5f16e
commit
463b360740
1 changed files with 2 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
from uuid import UUID
|
from uuid import UUID
|
||||||
from sqlalchemy import select
|
from sqlalchemy import select
|
||||||
from sqlalchemy.orm import joinedload
|
from sqlalchemy.orm import selectinload
|
||||||
import sqlalchemy.exc
|
import sqlalchemy.exc
|
||||||
from cognee.infrastructure.databases.relational import get_relational_engine
|
from cognee.infrastructure.databases.relational import get_relational_engine
|
||||||
from cognee.infrastructure.databases.exceptions import EntityNotFoundError
|
from cognee.infrastructure.databases.exceptions import EntityNotFoundError
|
||||||
|
|
@ -14,7 +14,7 @@ async def get_user(user_id: UUID):
|
||||||
user = (
|
user = (
|
||||||
await session.execute(
|
await session.execute(
|
||||||
select(User)
|
select(User)
|
||||||
.options(joinedload(User.roles), joinedload(User.tenant))
|
.options(selectinload(User.roles), selectinload(User.tenant))
|
||||||
.where(User.id == user_id)
|
.where(User.id == user_id)
|
||||||
)
|
)
|
||||||
).scalar()
|
).scalar()
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue