overview
Currently exceptions from a step raise as a CallableRuntimeError.
https://github.com/aws/aws-durable-execution-sdk-python/blob/3aea45710cc8da739f6d6ddb3b4120002b35f81d/src/aws_durable_execution_sdk_python/state.py#L188C1-L201C53
A recent refactor in Ts introduced some different/new error types.
ChildContextError Consistency:
- Always wrap errors in ChildContextError in executeChildContext
- Preserve original error message and pass error as cause
- Handle both Error objects and non-Error values consistently
- Add test for child context error with no Error field
StepError Consistency:
- Wrap generic errors in StepError at handler level
- Preserve DurableOperationError instances and specific error types
- Add test to verify Error objects are wrapped with correct message/cause
StepInterruptedError Handling:
- Pass StepInterruptedError to retry strategy for decision making
- Wrap StepInterruptedError in StepError when retry is exhausted
- Update tests to verify proper error wrapping and retry flow
per aws/aws-durable-execution-sdk-js#212
ac
- Add ChiildContextError + implement in ChildContext handler
- Add StepError + implement in Step handler (replacing CallabeRuntimeError)
- StepInterruptedError raises as a StepError when retries exhausted
overview
Currently exceptions from a step raise as a
CallableRuntimeError.https://github.com/aws/aws-durable-execution-sdk-python/blob/3aea45710cc8da739f6d6ddb3b4120002b35f81d/src/aws_durable_execution_sdk_python/state.py#L188C1-L201C53
A recent refactor in Ts introduced some different/new error types.
ChildContextError Consistency:
StepError Consistency:
StepInterruptedError Handling:
per aws/aws-durable-execution-sdk-js#212
ac