Skip to content

Commit

Permalink
cancelled added to transition states
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronald Krist committed Dec 12, 2024
1 parent 89ad053 commit 0522af2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion oarepo_workflows/requests/requests.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,10 +144,11 @@ class WorkflowTransitions:
submitted: Optional[str] = None
accepted: Optional[str] = None
declined: Optional[str] = None
cancelled: Optional[str] = None

def __getitem__(self, transition_name: str):
"""Get the transition by name."""
if transition_name not in ["submitted", "accepted", "declined"]:
if transition_name not in ["submitted", "accepted", "declined", "cancelled"]:
raise KeyError(
f"Transition {transition_name} not defined in {self.__class__.__name__}"
)
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = oarepo-workflows
version = 1.1.4
version = 1.1.5
description =
authors = Ronald Krist <[email protected]>
readme = README.md
Expand Down

0 comments on commit 0522af2

Please sign in to comment.