class documentation

Undocumented

Method __init__ Undocumented
Method activate Handle an activation and return completion.
Method call_at Undocumented
Method call_exception_handler Undocumented
Method call_later Undocumented
Method call_soon Undocumented
Method create_future Undocumented
Method create_task Undocumented
Method default_exception_handler Undocumented
Method get_debug Undocumented
Method get_exception_handler Undocumented
Method set_exception_handler Undocumented
Method time Undocumented
Method workflow_continue_as_new Undocumented
Method workflow_extern_functions Undocumented
Method workflow_get_current_build_id Undocumented
Method workflow_get_current_history_length Undocumented
Method workflow_get_current_history_size Undocumented
Method workflow_get_external_workflow_handle Undocumented
Method workflow_get_query_handler Undocumented
Method workflow_get_signal_handler Undocumented
Method workflow_get_update_handler Undocumented
Method workflow_get_update_validator Undocumented
Method workflow_info Undocumented
Method workflow_is_continue_as_new_suggested Undocumented
Method workflow_is_replaying Undocumented
Method workflow_memo Undocumented
Method workflow_memo_value Undocumented
Method workflow_metric_meter Undocumented
Method workflow_patch Undocumented
Method workflow_payload_converter Undocumented
Method workflow_random Undocumented
Method workflow_set_query_handler Undocumented
Method workflow_set_signal_handler Undocumented
Method workflow_set_update_handler Undocumented
Method workflow_start_activity Undocumented
Async Method workflow_start_child_workflow Undocumented
Method workflow_start_local_activity Undocumented
Method workflow_time_ns Undocumented
Method workflow_upsert_search_attributes Undocumented
Async Method workflow_wait_condition Undocumented
Method _add_command Undocumented
Method _apply Undocumented
Method _apply_cancel_workflow Undocumented
Method _apply_do_update Undocumented
Method _apply_fire_timer Undocumented
Method _apply_notify_has_patch Undocumented
Method _apply_query_workflow Undocumented
Method _apply_remove_from_cache Undocumented
Method _apply_resolve_activity Undocumented
Method _apply_resolve_child_workflow_execution Undocumented
Method _apply_resolve_child_workflow_execution_start Undocumented
Method _apply_resolve_request_cancel_external_workflow Undocumented
Method _apply_resolve_signal_external_workflow Undocumented
Method _apply_signal_workflow Undocumented
Method _apply_start_workflow Undocumented
Method _apply_update_random_seed Undocumented
Method _as_read_only Undocumented
Method _assert_not_read_only Undocumented
Async Method _cancel_external_workflow Undocumented
Method _check_condition Undocumented
Method _convert_payloads Undocumented
Method _enhanced_stack_trace Undocumented
Method _is_workflow_failure_exception Undocumented
Method _next_seq Undocumented
Method _outbound_continue_as_new Undocumented
Method _outbound_schedule_activity Undocumented
Async Method _outbound_signal_child_workflow Undocumented
Async Method _outbound_signal_external_workflow Undocumented
Async Method _outbound_start_child_workflow Undocumented
Method _process_handler_args Undocumented
Method _process_signal_job Undocumented
Method _register_task Undocumented
Method _run_once Undocumented
Async Method _run_top_level_workflow_function Undocumented
Method _set_workflow_failure Undocumented
Async Method _signal_external_workflow Undocumented
Method _stack_trace Undocumented
Method _timer_handle_cancelled Undocumented
Instance Variable _buffered_signals Undocumented
Instance Variable _cancel_requested Undocumented
Instance Variable _conditions Undocumented
Instance Variable _continue_as_new_suggested Undocumented
Instance Variable _curr_seqs Undocumented
Instance Variable _current_activation_error Undocumented
Instance Variable _current_build_id Undocumented
Instance Variable _current_completion Undocumented
Instance Variable _current_history_length Undocumented
Instance Variable _current_history_size Undocumented
Instance Variable _defn Undocumented
Instance Variable _deleting Undocumented
Instance Variable _disable_eager_activity_execution Undocumented
Instance Variable _exception_handler Undocumented
Instance Variable _extern_functions Undocumented
Instance Variable _failure_converter Undocumented
Instance Variable _inbound Undocumented
Instance Variable _info Undocumented
Instance Variable _is_replaying Undocumented
Instance Variable _memo Undocumented
Instance Variable _metric_meter Undocumented
Instance Variable _object Undocumented
Instance Variable _outbound Undocumented
Instance Variable _patches_memoized Undocumented
Instance Variable _patches_notified Undocumented
Instance Variable _payload_converter Undocumented
Instance Variable _pending_activities Undocumented
Instance Variable _pending_child_workflows Undocumented
Instance Variable _pending_external_cancels Undocumented
Instance Variable _pending_external_signals Undocumented
Instance Variable _pending_timers Undocumented
Instance Variable _primary_task Undocumented
Instance Variable _queries Undocumented
Instance Variable _random Undocumented
Instance Variable _read_only Undocumented
Instance Variable _ready Undocumented
Instance Variable _signals Undocumented
Instance Variable _tasks Undocumented
Instance Variable _time_ns Undocumented
Instance Variable _updates Undocumented
Instance Variable _worker_level_failure_exception_types Undocumented

Inherited from _Runtime (via WorkflowInstance):

Static Method current Undocumented
Static Method maybe_current Undocumented
Static Method set_on_loop Undocumented
Property logger_details Undocumented
Instance Variable _logger_details Undocumented

Handle an activation and return completion.

This should never raise an exception, but instead catch all exceptions and set as completion failure.

Parameters
act:temporalio.bridge.proto.workflow_activation.WorkflowActivationProtobuf activation.
Returns
temporalio.bridge.proto.workflow_completion.WorkflowActivationCompletionCompletion object with successful commands set or failure info set.
def call_at(self, when: float, callback: Callable[..., Any], *args: Any, context: Optional[contextvars.Context] = None) -> asyncio.TimerHandle: (source)

Undocumented

def call_exception_handler(self, context: _Context): (source)

Undocumented

def call_later(self, delay: float, callback: Callable[..., Any], *args: Any, context: Optional[contextvars.Context] = None) -> asyncio.TimerHandle: (source)

Undocumented

def call_soon(self, callback: Callable[..., Any], *args: Any, context: Optional[contextvars.Context] = None) -> asyncio.Handle: (source)

Undocumented

def create_future(self) -> asyncio.Future[Any]: (source)

Undocumented

def create_task(self, coro: Union[Awaitable[_T], Generator[Any, None, _T]], *, name: Optional[str] = None, context: Optional[contextvars.Context] = None) -> asyncio.Task[_T]: (source)

Undocumented

def default_exception_handler(self, context: _Context): (source)

Undocumented

def get_debug(self) -> bool: (source)

Undocumented

def get_exception_handler(self) -> Optional[_ExceptionHandler]: (source)

Undocumented

def set_exception_handler(self, handler: Optional[_ExceptionHandler]): (source)

Undocumented

def time(self) -> float: (source)

Undocumented

def workflow_extern_functions(self) -> Mapping[str, Callable]: (source)
def workflow_get_current_build_id(self) -> str: (source)
def workflow_get_current_history_length(self) -> int: (source)
def workflow_get_current_history_size(self) -> int: (source)
def workflow_get_external_workflow_handle(self, id: str, *, run_id: Optional[str]) -> temporalio.workflow.ExternalWorkflowHandle[Any]: (source)
def workflow_get_query_handler(self, name: Optional[str]) -> Optional[Callable]: (source)
def workflow_get_signal_handler(self, name: Optional[str]) -> Optional[Callable]: (source)
def workflow_get_update_handler(self, name: Optional[str]) -> Optional[Callable]: (source)
def workflow_get_update_validator(self, name: Optional[str]) -> Optional[Callable]: (source)
def workflow_is_continue_as_new_suggested(self) -> bool: (source)
def workflow_is_replaying(self) -> bool: (source)
def workflow_memo(self) -> Mapping[str, Any]: (source)
def workflow_memo_value(self, key: str, default: Any, *, type_hint: Optional[Type]) -> Any: (source)
def workflow_patch(self, id: str, *, deprecated: bool) -> bool: (source)
def workflow_random(self) -> random.Random: (source)
def workflow_set_query_handler(self, name: Optional[str], handler: Optional[Callable]): (source)
def workflow_set_signal_handler(self, name: Optional[str], handler: Optional[Callable]): (source)
def workflow_set_update_handler(self, name: Optional[str], handler: Optional[Callable], validator: Optional[Callable]): (source)
def workflow_start_activity(self, activity: Any, *args: Any, task_queue: Optional[str], result_type: Optional[Type], schedule_to_close_timeout: Optional[timedelta], schedule_to_start_timeout: Optional[timedelta], start_to_close_timeout: Optional[timedelta], heartbeat_timeout: Optional[timedelta], retry_policy: Optional[temporalio.common.RetryPolicy], cancellation_type: temporalio.workflow.ActivityCancellationType, activity_id: Optional[str], versioning_intent: Optional[temporalio.workflow.VersioningIntent]) -> temporalio.workflow.ActivityHandle[Any]: (source)
async def workflow_start_child_workflow(self, workflow: Any, *args: Any, id: str, task_queue: Optional[str], result_type: Optional[Type], cancellation_type: temporalio.workflow.ChildWorkflowCancellationType, parent_close_policy: temporalio.workflow.ParentClosePolicy, execution_timeout: Optional[timedelta], run_timeout: Optional[timedelta], task_timeout: Optional[timedelta], id_reuse_policy: temporalio.common.WorkflowIDReusePolicy, retry_policy: Optional[temporalio.common.RetryPolicy], cron_schedule: str, memo: Optional[Mapping[str, Any]], search_attributes: Optional[Union[temporalio.common.SearchAttributes, temporalio.common.TypedSearchAttributes]], versioning_intent: Optional[temporalio.workflow.VersioningIntent]) -> temporalio.workflow.ChildWorkflowHandle[Any, Any]: (source)
def workflow_start_local_activity(self, activity: Any, *args: Any, result_type: Optional[Type], schedule_to_close_timeout: Optional[timedelta], schedule_to_start_timeout: Optional[timedelta], start_to_close_timeout: Optional[timedelta], retry_policy: Optional[temporalio.common.RetryPolicy], local_retry_threshold: Optional[timedelta], cancellation_type: temporalio.workflow.ActivityCancellationType, activity_id: Optional[str]) -> temporalio.workflow.ActivityHandle[Any]: (source)
def workflow_time_ns(self) -> int: (source)
async def workflow_wait_condition(self, fn: Callable[[], bool], *, timeout: Optional[float] = None): (source)

Undocumented

Undocumented

Undocumented

Undocumented

Undocumented

Undocumented

Undocumented

def _apply_resolve_child_workflow_execution_start(self, job: temporalio.bridge.proto.workflow_activation.ResolveChildWorkflowExecutionStart): (source)

Undocumented

def _apply_resolve_request_cancel_external_workflow(self, job: temporalio.bridge.proto.workflow_activation.ResolveRequestCancelExternalWorkflow): (source)

Undocumented

Undocumented

Undocumented

Undocumented

Undocumented

@contextmanager
def _as_read_only(self) -> Iterator[None]: (source)

Undocumented

def _assert_not_read_only(self, action_attempted: str, *, allow_during_delete: bool = False): (source)

Undocumented

async def _cancel_external_workflow(self, command: temporalio.bridge.proto.workflow_commands.WorkflowCommand): (source)

Undocumented

def _check_condition(self, fn: Callable[[], bool], fut: asyncio.Future) -> bool: (source)

Undocumented

def _convert_payloads(self, payloads: Sequence[temporalio.api.common.v1.Payload], types: Optional[List[Type]]) -> List[Any]: (source)

Undocumented

def _enhanced_stack_trace(self) -> temporalio.api.sdk.v1.EnhancedStackTrace: (source)

Undocumented

def _is_workflow_failure_exception(self, err: BaseException) -> bool: (source)

Undocumented

def _next_seq(self, type: str) -> int: (source)

Undocumented

def _outbound_continue_as_new(self, input: ContinueAsNewInput) -> NoReturn: (source)

Undocumented

def _outbound_schedule_activity(self, input: Union[StartActivityInput, StartLocalActivityInput]) -> _ActivityHandle: (source)

Undocumented

async def _outbound_signal_child_workflow(self, input: SignalChildWorkflowInput): (source)

Undocumented

async def _outbound_signal_external_workflow(self, input: SignalExternalWorkflowInput): (source)

Undocumented

async def _outbound_start_child_workflow(self, input: StartChildWorkflowInput) -> _ChildWorkflowHandle: (source)

Undocumented

def _process_handler_args(self, job_name: str, job_input: Sequence[temporalio.api.common.v1.Payload], defn_name: Optional[str], defn_arg_types: Optional[List[Type]], defn_dynamic_vararg: bool) -> List[Any]: (source)

Undocumented

def _register_task(self, task: asyncio.Task, *, name: Optional[str]): (source)

Undocumented

def _run_once(self, *, check_conditions: bool): (source)

Undocumented

async def _run_top_level_workflow_function(self, coro: Awaitable[None]): (source)

Undocumented

def _set_workflow_failure(self, err: BaseException): (source)

Undocumented

async def _signal_external_workflow(self, command: temporalio.bridge.proto.workflow_commands.WorkflowCommand): (source)

Undocumented

def _stack_trace(self) -> str: (source)

Undocumented

def _timer_handle_cancelled(self, handle: asyncio.TimerHandle): (source)

Undocumented

_cancel_requested: bool = (source)

Undocumented

Undocumented

_continue_as_new_suggested = (source)

Undocumented

_curr_seqs: Dict[str, int] = (source)

Undocumented

_current_activation_error: Optional[Exception] = (source)

Undocumented

_current_build_id = (source)

Undocumented

_current_completion = (source)

Undocumented

_current_history_length = (source)

Undocumented

_current_history_size = (source)

Undocumented

Undocumented

_deleting: bool = (source)

Undocumented

_disable_eager_activity_execution = (source)

Undocumented

_exception_handler = (source)

Undocumented

_extern_functions = (source)

Undocumented

_failure_converter = (source)

Undocumented

_inbound = (source)

Undocumented

Undocumented

_is_replaying: bool = (source)

Undocumented

Undocumented

_metric_meter = (source)

Undocumented

Undocumented

_outbound = (source)

Undocumented

_patches_memoized: Dict[str, bool] = (source)

Undocumented

_patches_notified: Set[str] = (source)

Undocumented

_payload_converter = (source)

Undocumented

_pending_activities: Dict[int, _ActivityHandle] = (source)

Undocumented

_pending_child_workflows: Dict[int, _ChildWorkflowHandle] = (source)

Undocumented

_pending_external_cancels: Dict[int, asyncio.Future] = (source)

Undocumented

_pending_external_signals: Dict[int, asyncio.Future] = (source)

Undocumented

_pending_timers: Dict[int, _TimerHandle] = (source)

Undocumented

_primary_task = (source)

Undocumented

_queries = (source)

Undocumented

Undocumented

_read_only: bool = (source)

Undocumented

_signals = (source)

Undocumented

Undocumented

_time_ns = (source)

Undocumented

_updates = (source)

Undocumented

_worker_level_failure_exception_types = (source)

Undocumented