@@ -2739,17 +2739,21 @@ class _WorkflowBeingEvictedError(BaseException):
2739
2739
2740
2740
@dataclass
2741
2741
class HandlerExecution :
2742
+ """Information about an execution of a signal or update handler."""
2742
2743
name : str
2743
2744
unfinished_handlers_policy : temporalio .workflow .UnfinishedHandlersPolicy
2744
2745
id : Optional [str ] = None
2745
2746
2746
2747
2747
2748
class UnfinishedUpdateHandlerWarning (RuntimeWarning ):
2749
+ """Warning issued when a workflow exits before an update handler has finished executing"""
2748
2750
def __init__ (self , handler_executions : List [HandlerExecution ]) -> None :
2751
+ """Initialize warning object"""
2749
2752
super ().__init__ ()
2750
2753
self .handler_executions = handler_executions
2751
2754
2752
2755
def __str__ (self ) -> str :
2756
+ """Return warning message"""
2753
2757
message = """
2754
2758
Workflow finished while update handlers are still running. This may have interrupted work that the
2755
2759
update handler was doing, and the client that sent the update will receive a 'workflow execution
@@ -2771,11 +2775,14 @@ def __str__(self) -> str:
2771
2775
2772
2776
2773
2777
class UnfinishedSignalHandlerWarning (RuntimeWarning ):
2778
+ """Warning issued when a workflow exits before a signal handler has finished executing"""
2774
2779
def __init__ (self , handler_executions : List [HandlerExecution ]) -> None :
2780
+ """Initialize warning object"""
2775
2781
super ().__init__ ()
2776
2782
self .handler_executions = handler_executions
2777
2783
2778
2784
def __str__ (self ) -> str :
2785
+ """Return warning message"""
2779
2786
message = """
2780
2787
Workflow finished while signal handlers are still running. This may have interrupted work that the
2781
2788
signal handler was doing. You can wait for all update and signal handlers to complete by using
0 commit comments