From 4a1ebb110be7231c42cd845899f3061d62e4b841 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Gurhem?= Date: Mon, 2 Sep 2024 10:26:05 +0200 Subject: [PATCH] feat: add Waiting for dependencies and paused statuses --- Protos/V1/task_status.proto | 2 ++ packages/python/src/armonik/common/enumwrapper.py | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Protos/V1/task_status.proto b/Protos/V1/task_status.proto index 9855c85f6..b595a73bc 100644 --- a/Protos/V1/task_status.proto +++ b/Protos/V1/task_status.proto @@ -23,4 +23,6 @@ enum TaskStatus { TASK_STATUS_PROCESSING = 9; /** Task is being processed. */ TASK_STATUS_PROCESSED = 10; /** Task is processed. */ TASK_STATUS_RETRIED = 11; /** Task is retried. */ + TASK_STATUS_WAITING_FOR_DEPENDENCIES = 12; /** Task is waiting for its dependencies before becoming executable. */ + TASK_STATUS_PAUSED = 11; /** Task is paused and will not be executed until session is resumed. */ } diff --git a/packages/python/src/armonik/common/enumwrapper.py b/packages/python/src/armonik/common/enumwrapper.py index 5868031f4..a8462ab18 100644 --- a/packages/python/src/armonik/common/enumwrapper.py +++ b/packages/python/src/armonik/common/enumwrapper.py @@ -14,6 +14,8 @@ TASK_STATUS_PROCESSING, TASK_STATUS_PROCESSED, TASK_STATUS_RETRIED, + TASK_STATUS_WAITING_FOR_DEPENDENCIES, + TASK_STATUS_PAUSED, ) from ..protogen.common.events_common_pb2 import ( EVENTS_ENUM_UNSPECIFIED, @@ -69,7 +71,8 @@ class TaskStatus(IntEnum): PROCESSING = TASK_STATUS_PROCESSING PROCESSED = TASK_STATUS_PROCESSED RETRIED = TASK_STATUS_RETRIED - + WAITING_FOR_DEPENDENCIES = TASK_STATUS_WAITING_FOR_DEPENDENCIES + PAUSED = TASK_STATUS_PAUSED class EventTypes: UNSPECIFIED = EVENTS_ENUM_UNSPECIFIED