module documentation

Common Temporal exceptions.

Class ActivityError Error raised on activity failure.
Class ApplicationError Error raised during workflow/activity execution.
Class CancelledError Error raised on workflow/activity cancellation.
Class ChildWorkflowError Error raised on child workflow failure.
Class FailureError Base for runtime failures during workflow/activity execution.
Class RetryState Current retry state of the workflow/activity during error.
Class ServerError Error originating in the Temporal server.
Class TemporalError Base for all Temporal exceptions.
Class TerminatedError Error raised on workflow cancellation.
Class TimeoutError Error raised on workflow/activity timeout.
Class TimeoutType Type of timeout for TimeoutError.
Class WorkflowAlreadyStartedError Thrown by a client or workflow when a workflow execution has already started.
Function apply_error_to_failure Convert the given failure error to a Temporal failure.
Function apply_exception_to_failure Small wrapper around apply_error_to_failure for exceptions.
Async Function decode_failure Decode payloads within the failure using the given codec.
Async Function decode_failure_to_error Shortcut for decode_failure + failure_to_error.
Async Function encode_error_to_failure Shortcut for apply_error_to_failure + encode_failure.
Async Function encode_exception_to_failure Shortcut for apply_exception_to_failure + encode_failure.
Async Function encode_failure Encode payloads within the failure using the given codec.
Function failure_to_error Create a FailureError from the given protobuf failure and data converter.
Async Function _apply_to_failure_payloads Undocumented
def apply_error_to_failure(error: FailureError, converter: temporalio.converter.PayloadConverter, failure: temporalio.api.failure.v1.Failure): (source)

Convert the given failure error to a Temporal failure.

Parameters
error:FailureErrorPython failure error.
converter:temporalio.converter.PayloadConverterConverter used for translating error details.
failure:temporalio.api.failure.v1.FailureInternal Temporal failure to populate.
def apply_exception_to_failure(exception: BaseException, converter: temporalio.converter.PayloadConverter, failure: temporalio.api.failure.v1.Failure): (source)

Small wrapper around apply_error_to_failure for exceptions.

async def decode_failure(failure: temporalio.api.failure.v1.Failure, codec: temporalio.converter.PayloadCodec): (source)

Decode payloads within the failure using the given codec.

async def decode_failure_to_error(failure: temporalio.api.failure.v1.Failure, converter: temporalio.converter.DataConverter) -> FailureError: (source)
async def encode_error_to_failure(error: FailureError, converter: temporalio.converter.DataConverter, failure: temporalio.api.failure.v1.Failure): (source)
async def encode_exception_to_failure(exception: BaseException, converter: temporalio.converter.DataConverter, failure: temporalio.api.failure.v1.Failure): (source)
async def encode_failure(failure: temporalio.api.failure.v1.Failure, codec: temporalio.converter.PayloadCodec): (source)

Encode payloads within the failure using the given codec.

def failure_to_error(failure: temporalio.api.failure.v1.Failure, converter: temporalio.converter.PayloadConverter) -> FailureError: (source)

Create a FailureError from the given protobuf failure and data converter.

async def _apply_to_failure_payloads(failure: temporalio.api.failure.v1.Failure, cb: Callable[[temporalio.api.common.v1.Payloads], Awaitable[None]]): (source)

Undocumented