In an edge case where the Operations collection is empty on invoke due to size, it then later gets constructed via paginated api calls to
execution_state.fetch_paginated_operations(
invocation_input.initial_execution_state.operations,
invocation_input.checkpoint_token,
invocation_input.initial_execution_state.next_marker,
)
https://github.com/aws/aws-durable-execution-sdk-python/blob/main/src/aws_durable_execution_sdk_python/execution.py#L330
The actual InputPayload will be on the EXECUTION operation after this fetch, whereas in the code currently it just uses the original input (which might be none)
raw_input_payload: str | None = (
invocation_input.initial_execution_state.get_input_payload()
)
input_event: MutableMapping[str, Any] = {}
if raw_input_payload and raw_input_payload.strip():
try:
input_event = json.loads(raw_input_payload)
...
user_future = executor.submit(func, input_event, durable_context)
|
user_future = executor.submit(func, input_event, durable_context) |
Note this is not actually happening today due to how backend currently works, nonetheless, this is a flaw in the SDK logic.
In an edge case where the Operations collection is empty on invoke due to size, it then later gets constructed via paginated api calls to
https://github.com/aws/aws-durable-execution-sdk-python/blob/main/src/aws_durable_execution_sdk_python/execution.py#L330
The actual
InputPayloadwill be on the EXECUTION operation after this fetch, whereas in the code currently it just uses the original input (which might be none)aws-durable-execution-sdk-python/src/aws_durable_execution_sdk_python/execution.py
Line 330 in e5824f1
Note this is not actually happening today due to how backend currently works, nonetheless, this is a flaw in the SDK logic.