Skip to content

Commit b9cdc39

Browse files
author
Tomas Pflanzer
committed
fix: convert string run_id to UUID in worker for SQLite compat
1 parent 9f65263 commit b9cdc39

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/sandcastle/queue/worker.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,13 @@ async def run_workflow_job(
4949

5050
logger.info(f"Worker picked up run {run_id}")
5151

52+
import uuid as _uuid
53+
run_uuid = _uuid.UUID(run_id) if isinstance(run_id, str) else run_id
54+
5255
callback_url = None
5356

5457
async with async_session() as session:
55-
run = await session.get(Run, run_id)
58+
run = await session.get(Run, run_uuid)
5659
if run:
5760
run.status = RunStatus.RUNNING
5861
run.started_at = datetime.now(timezone.utc)

0 commit comments

Comments
 (0)