mirror of
https://github.com/dograh-hq/dograh.git
synced 2026-06-25 08:48:13 +02:00
chore: bump pipecat version and fix tests (#263)
* chore: bump pipecat version and fix tests * chore: add github workflow to run tests * fix: install reqirements.dev.txt in test script * fix: fix api-test action * feat: add integration test * test: add integration tests * test: add test for function call mute strategy
This commit is contained in:
parent
d256c6005c
commit
0e12c41fc7
76 changed files with 1776 additions and 670 deletions
|
|
@ -238,6 +238,22 @@ class WorkflowRunClient(BaseDBClient):
|
|||
)
|
||||
return result.scalars().first()
|
||||
|
||||
async def get_organization_id_by_workflow_run_id(
|
||||
self, run_id: int | None
|
||||
) -> int | None:
|
||||
"""Resolve organization_id from a workflow run via workflow.user."""
|
||||
if not run_id:
|
||||
return None
|
||||
async with self.async_session() as session:
|
||||
result = await session.execute(
|
||||
select(WorkflowModel.organization_id)
|
||||
.join(
|
||||
WorkflowRunModel, WorkflowRunModel.workflow_id == WorkflowModel.id
|
||||
)
|
||||
.where(WorkflowRunModel.id == run_id)
|
||||
)
|
||||
return result.scalar_one_or_none()
|
||||
|
||||
async def get_workflow_runs_by_workflow_id(
|
||||
self,
|
||||
workflow_id: int,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue