Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from pathlib import Path

from aws_durable_execution_sdk_python_testing.exceptions import (
DurableFunctionsLocalRunnerError,
ResourceNotFoundException,
)
from aws_durable_execution_sdk_python_testing.execution import Execution

Expand Down Expand Up @@ -74,7 +74,7 @@ def load(self, execution_arn: str) -> Execution:
file_path = self._get_file_path(execution_arn)
if not file_path.exists():
msg = f"Execution {execution_arn} not found"
raise DurableFunctionsLocalRunnerError(msg)
raise ResourceNotFoundException(msg)

with open(file_path, encoding="utf-8") as f:
data = json.load(f, object_hook=datetime_object_hook)
Expand Down
6 changes: 3 additions & 3 deletions tests/stores/filesystem_store_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import pytest

from aws_durable_execution_sdk_python_testing.exceptions import (
DurableFunctionsLocalRunnerError,
ResourceNotFoundException,
)
from aws_durable_execution_sdk_python_testing.execution import Execution
from aws_durable_execution_sdk_python_testing.model import StartDurableExecutionInput
Expand Down Expand Up @@ -64,9 +64,9 @@ def test_filesystem_execution_store_save_and_load(store, sample_execution):


def test_filesystem_execution_store_load_nonexistent(store):
"""Test loading a nonexistent execution raises DurableFunctionsLocalRunnerError."""
"""Test loading a nonexistent execution raises ResourceNotFoundException."""
with pytest.raises(
DurableFunctionsLocalRunnerError, match="Execution nonexistent-arn not found"
ResourceNotFoundException, match="Execution nonexistent-arn not found"
):
store.load("nonexistent-arn")

Expand Down
Loading