From 59594e01acc91eb502cb08c43febeb3202bf6833 Mon Sep 17 00:00:00 2001 From: Igor Ilic <30923996+dexters1@users.noreply.github.com> Date: Wed, 23 Jul 2025 06:47:38 +0200 Subject: [PATCH] fix: add missing await for getting default user (#1131) ## Description ## DCO Affirmation I affirm that all code in every commit of this pull request conforms to the terms of the Topoteretes Developer Certificate of Origin. --- cognee/modules/pipelines/operations/run_tasks.py | 2 +- cognee/modules/pipelines/operations/run_tasks_distributed.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cognee/modules/pipelines/operations/run_tasks.py b/cognee/modules/pipelines/operations/run_tasks.py index 46f979aaa..926d433fe 100644 --- a/cognee/modules/pipelines/operations/run_tasks.py +++ b/cognee/modules/pipelines/operations/run_tasks.py @@ -58,7 +58,7 @@ async def run_tasks( context: dict = None, ): if not user: - user = get_default_user() + user = await get_default_user() # Get Dataset object db_engine = get_relational_engine() diff --git a/cognee/modules/pipelines/operations/run_tasks_distributed.py b/cognee/modules/pipelines/operations/run_tasks_distributed.py index 30c4fb073..d7dc2a403 100644 --- a/cognee/modules/pipelines/operations/run_tasks_distributed.py +++ b/cognee/modules/pipelines/operations/run_tasks_distributed.py @@ -44,7 +44,7 @@ if modal: async def run_tasks_distributed(tasks, dataset_id, data, user, pipeline_name, context): if not user: - user = get_default_user() + user = await get_default_user() db_engine = get_relational_engine() async with db_engine.get_async_session() as session: