2828 DBOSAwaitedWorkflowCancelledError ,
2929 DBOSConflictingRegistrationError ,
3030 DBOSMaxStepRetriesExceeded ,
31- DBOSWorkflowCancelledError ,
3231)
3332from dbos ._schemas .system_database import SystemSchema
3433from dbos ._sys_db import GetWorkflowsInput
@@ -1493,7 +1492,7 @@ def blocked_workflow() -> None:
14931492 # Verify a blocked workflow called with a timeout is cancelled
14941493 wfid = str (uuid .uuid4 ())
14951494 with SetWorkflowTimeout (0.1 ):
1496- with pytest .raises (DBOSWorkflowCancelledError ):
1495+ with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
14971496 with SetWorkflowID (wfid ):
14981497 blocked_workflow ()
14991498 assert assert_current_dbos_context ().workflow_deadline_epoch_ms is None
@@ -1505,7 +1504,7 @@ def blocked_workflow() -> None:
15051504 status .workflow_deadline_epoch_ms is not None
15061505 and status .workflow_deadline_epoch_ms > start_time
15071506 )
1508- with pytest .raises (DBOSWorkflowCancelledError ):
1507+ with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
15091508 handle .get_result ()
15101509
15111510 # Change the workflow status to pending
@@ -1518,17 +1517,17 @@ def blocked_workflow() -> None:
15181517 # Recover the workflow, verify it still times out
15191518 handles = DBOS ._recover_pending_workflows ()
15201519 assert len (handles ) == 1
1521- with pytest .raises (DBOSWorkflowCancelledError ):
1520+ with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
15221521 handles [0 ].get_result ()
15231522
15241523 @DBOS .workflow ()
15251524 def parent_workflow_with_timeout () -> None :
15261525 assert assert_current_dbos_context ().workflow_deadline_epoch_ms is None
15271526 with SetWorkflowTimeout (0.1 ):
1528- with pytest .raises (DBOSWorkflowCancelledError ):
1527+ with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
15291528 blocked_workflow ()
15301529 handle = DBOS .start_workflow (blocked_workflow )
1531- with pytest .raises (DBOSWorkflowCancelledError ):
1530+ with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
15321531 handle .get_result ()
15331532 assert assert_current_dbos_context ().workflow_deadline_epoch_ms is None
15341533
@@ -1549,7 +1548,7 @@ def parent_workflow() -> None:
15491548 # Verify if a parent called with a timeout calls a blocked child
15501549 # the deadline propagates and the children are also cancelled.
15511550 with SetWorkflowTimeout (1.0 ):
1552- with pytest .raises (DBOSWorkflowCancelledError ):
1551+ with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
15531552 parent_workflow ()
15541553
15551554 with pytest .raises (DBOSAwaitedWorkflowCancelledError ):
0 commit comments