Return 409 on workflow updates race conditions (#4510)
This commit is contained in:
committed by
GitHub
parent
f879f4983c
commit
f781a6f0ef
@@ -54,6 +54,14 @@ class FailedToUpdateWorkflow(BaseWorkflowHTTPException):
|
||||
)
|
||||
|
||||
|
||||
class WorkflowVersionConflict(BaseWorkflowHTTPException):
|
||||
def __init__(self, workflow_permanent_id: str) -> None:
|
||||
super().__init__(
|
||||
f"Concurrent update detected for workflow {workflow_permanent_id}. Please retry.",
|
||||
status_code=status.HTTP_409_CONFLICT,
|
||||
)
|
||||
|
||||
|
||||
class OutputParameterKeyCollisionError(BaseWorkflowHTTPException):
|
||||
def __init__(self, key: str, retry_count: int | None = None) -> None:
|
||||
message = f"Output parameter key {key} already exists in the context manager."
|
||||
|
||||
Reference in New Issue
Block a user