mirror of
https://github.com/Skyvern-AI/skyvern.git
synced 2025-09-15 09:49:46 +00:00
Return only standalone tasks, no workflow tasks in /runs (#1716)
This commit is contained in:
parent
d34a403c8f
commit
95ee4c6088
1 changed files with 5 additions and 1 deletions
|
@ -1409,7 +1409,11 @@ class AgentDB:
|
||||||
convert_to_workflow_run(run, debug_enabled=self.debug_enabled) for run in workflow_run_query_result
|
convert_to_workflow_run(run, debug_enabled=self.debug_enabled) for run in workflow_run_query_result
|
||||||
]
|
]
|
||||||
|
|
||||||
task_query = select(TaskModel).filter(TaskModel.organization_id == organization_id)
|
task_query = (
|
||||||
|
select(TaskModel)
|
||||||
|
.filter(TaskModel.organization_id == organization_id)
|
||||||
|
.filter(TaskModel.workflow_run_id.is_(None))
|
||||||
|
)
|
||||||
if status:
|
if status:
|
||||||
task_query = task_query.filter(TaskModel.status.in_(status))
|
task_query = task_query.filter(TaskModel.status.in_(status))
|
||||||
task_query = task_query.order_by(TaskModel.created_at.desc()).limit(limit)
|
task_query = task_query.order_by(TaskModel.created_at.desc()).limit(limit)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue