fix(kanban): use 'is not None' check for max_runtime_seconds in create_task

max_runtime_seconds=0 was being silently coerced to None due to a falsy
check (if max_runtime_seconds). Zero is a valid value that causes the
dispatcher to immediately time out a task. The adjacent max_retries
parameter already used the correct 'is not None' pattern.

Fixes the inconsistency by aligning max_runtime_seconds with max_retries.
This commit is contained in:
sprmn24 2026-05-18 20:16:08 -07:00 committed by Teknium
parent 40c1decb3b
commit 5db0d72c90

View file

@ -1408,7 +1408,7 @@ def create_task(
workspace_path,
tenant,
idempotency_key,
int(max_runtime_seconds) if max_runtime_seconds else None,
int(max_runtime_seconds) if max_runtime_seconds is not None else None,
json.dumps(skills_list) if skills_list is not None else None,
int(max_retries) if max_retries is not None else None,
),