aws-durable-execution-sdk-python-testing 1.2.0__py3-none-any.whl → 1.3.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. aws_durable_execution_sdk_python_testing/__about__.py +1 -1
  2. aws_durable_execution_sdk_python_testing/checkpoint/core.py +171 -0
  3. aws_durable_execution_sdk_python_testing/checkpoint/effects.py +61 -0
  4. aws_durable_execution_sdk_python_testing/checkpoint/processor.py +124 -45
  5. aws_durable_execution_sdk_python_testing/checkpoint/processors/base.py +40 -14
  6. aws_durable_execution_sdk_python_testing/checkpoint/processors/callback.py +5 -2
  7. aws_durable_execution_sdk_python_testing/checkpoint/processors/context.py +6 -0
  8. aws_durable_execution_sdk_python_testing/checkpoint/processors/execution.py +4 -9
  9. aws_durable_execution_sdk_python_testing/checkpoint/processors/invoke.py +139 -0
  10. aws_durable_execution_sdk_python_testing/checkpoint/processors/step.py +15 -21
  11. aws_durable_execution_sdk_python_testing/checkpoint/processors/wait.py +10 -16
  12. aws_durable_execution_sdk_python_testing/checkpoint/transformer.py +145 -48
  13. aws_durable_execution_sdk_python_testing/checkpoint/validators/checkpoint.py +65 -8
  14. aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/invoke.py +79 -18
  15. aws_durable_execution_sdk_python_testing/child_dispatcher.py +828 -0
  16. aws_durable_execution_sdk_python_testing/cli.py +48 -1
  17. aws_durable_execution_sdk_python_testing/client.py +21 -10
  18. aws_durable_execution_sdk_python_testing/clock.py +69 -0
  19. aws_durable_execution_sdk_python_testing/exceptions.py +14 -0
  20. aws_durable_execution_sdk_python_testing/execution.py +583 -49
  21. aws_durable_execution_sdk_python_testing/executor.py +1813 -349
  22. aws_durable_execution_sdk_python_testing/invoker.py +356 -85
  23. aws_durable_execution_sdk_python_testing/model.py +81 -73
  24. aws_durable_execution_sdk_python_testing/observer.py +100 -88
  25. aws_durable_execution_sdk_python_testing/runner.py +407 -30
  26. aws_durable_execution_sdk_python_testing/scheduler.py +38 -13
  27. aws_durable_execution_sdk_python_testing/stores/filesystem.py +10 -2
  28. aws_durable_execution_sdk_python_testing/stores/sqlite.py +18 -6
  29. aws_durable_execution_sdk_python_testing/threads.py +157 -0
  30. aws_durable_execution_sdk_python_testing/token.py +11 -2
  31. aws_durable_execution_sdk_python_testing/web/handlers.py +33 -7
  32. aws_durable_execution_sdk_python_testing/web/routes.py +14 -6
  33. aws_durable_execution_sdk_python_testing/web/serialization.py +1 -2
  34. aws_durable_execution_sdk_python_testing/web/server.py +1 -1
  35. aws_durable_execution_sdk_python_testing/worker/__init__.py +9 -0
  36. aws_durable_execution_sdk_python_testing/worker/checkpoint_tasks.py +119 -0
  37. aws_durable_execution_sdk_python_testing/worker/execution_worker.py +117 -0
  38. aws_durable_execution_sdk_python_testing/worker/lane.py +118 -0
  39. aws_durable_execution_sdk_python_testing/worker/registry.py +124 -0
  40. aws_durable_execution_sdk_python_testing/worker/status.py +27 -0
  41. aws_durable_execution_sdk_python_testing/worker/task.py +57 -0
  42. {aws_durable_execution_sdk_python_testing-1.2.0.dist-info → aws_durable_execution_sdk_python_testing-1.3.0.dist-info}/METADATA +50 -58
  43. aws_durable_execution_sdk_python_testing-1.3.0.dist-info/RECORD +64 -0
  44. {aws_durable_execution_sdk_python_testing-1.2.0.dist-info → aws_durable_execution_sdk_python_testing-1.3.0.dist-info}/WHEEL +1 -1
  45. aws_durable_execution_sdk_python_testing/checkpoint/validators/transitions.py +0 -66
  46. aws_durable_execution_sdk_python_testing-1.2.0.dist-info/RECORD +0 -52
  47. {aws_durable_execution_sdk_python_testing-1.2.0.dist-info/licenses → aws_durable_execution_sdk_python_testing}/LICENSE +0 -0
  48. {aws_durable_execution_sdk_python_testing-1.2.0.dist-info/licenses → aws_durable_execution_sdk_python_testing}/NOTICE +0 -0
  49. {aws_durable_execution_sdk_python_testing-1.2.0.dist-info → aws_durable_execution_sdk_python_testing-1.3.0.dist-info}/entry_points.txt +0 -0
@@ -1,14 +1,12 @@
1
- Metadata-Version: 2.4
1
+ Metadata-Version: 2.5
2
2
  Name: aws-durable-execution-sdk-python-testing
3
- Version: 1.2.0
3
+ Version: 1.3.0
4
4
  Summary: AWS Durable Execution Testing SDK for Python
5
5
  Project-URL: Documentation, https://github.com/aws/aws-durable-execution-sdk-python-testing#readme
6
6
  Project-URL: Issues, https://github.com/aws/aws-durable-execution-sdk-python-testing/issues
7
7
  Project-URL: Source, https://github.com/aws/aws-durable-execution-sdk-python-testing
8
8
  Author-email: AWS durable-execution-dev <durable-execution-dev@amazon.com>
9
9
  License-Expression: Apache-2.0
10
- License-File: LICENSE
11
- License-File: NOTICE
12
10
  Classifier: Development Status :: 4 - Beta
13
11
  Classifier: Programming Language :: Python
14
12
  Classifier: Programming Language :: Python :: 3.11
@@ -18,7 +16,7 @@ Classifier: Programming Language :: Python :: 3.14
18
16
  Classifier: Programming Language :: Python :: Implementation :: CPython
19
17
  Classifier: Programming Language :: Python :: Implementation :: PyPy
20
18
  Requires-Python: >=3.11
21
- Requires-Dist: aws-durable-execution-sdk-python>=1.0.0
19
+ Requires-Dist: aws-durable-execution-sdk-python>=2.1.0
22
20
  Requires-Dist: boto3>=1.42.1
23
21
  Description-Content-Type: text/markdown
24
22
 
@@ -36,6 +34,7 @@ Description-Content-Type: text/markdown
36
34
 
37
35
  - [Installation](#installation)
38
36
  - [Quick Start](#quick-start)
37
+ - [Testing functions that invoke other functions](#testing-functions-that-invoke-other-functions)
39
38
  - [Architecture](#architecture)
40
39
  - [Documentation](#documentation)
41
40
  - [Developer Guide](#developers)
@@ -135,67 +134,60 @@ def test_my_durable_functions():
135
134
  three_result: StepOperation = result.get_step("three")
136
135
  assert three_result.result == '"5 6"'
137
136
  ```
138
- ## Architecture
139
- ![Durable Functions Python Test Framework Architecture](/assets/dar-python-test-framework-architecture.svg)
140
-
141
- ## Event Flow
142
- ![Event Flow Sequence Diagram](/assets/dar-python-test-framework-event-flow.svg)
143
-
144
- 1. **DurableTestRunner** starts execution via **Executor**
145
- 2. **Executor** creates **Execution** and schedules initial invocation
146
- 3. During execution, checkpoints are processed by **CheckpointProcessor**
147
- 4. **Individual Processors** transform operation updates and may trigger events
148
- 5. **ExecutionNotifier** broadcasts events to **Executor** (observer)
149
- 6. **Executor** updates **Execution** state based on events
150
- 7. **Execution** completion triggers final event notifications
151
- 8. **DurableTestRunner** run() blocks until it receives completion event, and then returns `DurableFunctionTestResult`.
137
+ ## Testing functions that invoke other functions
152
138
 
153
- ## Major Components
139
+ A durable function can call another function with `context.invoke`. The
140
+ runner needs to know each target's kind: a durable target runs as a
141
+ child durable execution with its own history, while a plain (non-durable)
142
+ target is one invocation whose return value is the result. An unknown
143
+ target fails the operation with `ResourceNotFoundException`.
154
144
 
155
- ### Core Execution Flow
156
- - **DurableTestRunner** - Main entry point that orchestrates test execution
157
- - **Executor** - Manages execution lifecycle. Mutates Execution.
158
- - **Execution** - Represents the state and operations of a single durable execution
145
+ ### In-process runner
159
146
 
160
- ### Service Client Integration
161
- - **InMemoryServiceClient** - Replaces AWS Lambda service client for local testing. Injected into SDK via `DurableExecutionInvocationInputWithClient`
147
+ Register each target with the runner. `register_durable_function` marks a
148
+ durable target, and takes its execution timeout and retention;
149
+ `register_function` marks a plain one. The runner has one handler per
150
+ registered name, not versions: an invoke of `child:prod` runs the handler
151
+ registered as `child:prod` if there is one, otherwise the one registered
152
+ as `child`.
162
153
 
163
- ### Checkpoint Processing Pipeline
164
- - **CheckpointProcessor** - Orchestrates operation transformations and validation
165
- - **Individual Validators** - Validate operation updates and state transitions
166
- - **Individual Processors** - Transform operation updates into operations (step, wait, callback, context, execution)
167
-
168
- ### Execution status changes (Observer Pattern)
169
- - **ExecutionNotifier** - Notifies observers of execution events
170
- - **ExecutionObserver** - Interface for receiving execution lifecycle events
171
- - **Executor** implements `ExecutionObserver` to handle completion events
172
-
173
- ## Component Relationships
154
+ ```python
155
+ from aws_durable_execution_sdk_python.context import DurableContext
156
+ from aws_durable_execution_sdk_python.execution import durable_execution
157
+ from aws_durable_execution_sdk_python_testing.runner import DurableFunctionTestRunner
174
158
 
175
- ### 1. DurableTestRunner → Executor → Execution
176
- - **DurableTestRunner** serves as the main API entry point and sets up all components
177
- - **Executor** manages the execution lifecycle, handling invocations and state transitions
178
- - **Execution** maintains the state of operations and completion status
159
+ @durable_execution
160
+ def process_payment(event: dict, context: DurableContext) -> dict:
161
+ return {"charged": event["amount"]}
179
162
 
180
- ### 2. Service Client Injection
181
- - **DurableTestRunner** creates **InMemoryServiceClient** with **CheckpointProcessor**
182
- - **InProcessInvoker** injects the service client into SDK via `DurableExecutionInvocationInputWithClient`
183
- - When durable functions call checkpoint operations, they're intercepted by **InMemoryServiceClient**
184
- - **InMemoryServiceClient** delegates to **CheckpointProcessor** for local processing
163
+ def lookup_price(event: dict, context) -> dict:
164
+ return {"price": 25}
185
165
 
186
- ### 3. CheckpointProcessor → Individual Validators → Individual Processors
187
- - **CheckpointProcessor** orchestrates the checkpoint processing pipeline
188
- - **Individual Validators** (CheckpointValidator, TransitionsValidator, and operation-specific validators) ensure operation updates are valid
189
- - **Individual Processors** (StepProcessor, WaitProcessor, etc.) transform `OperationUpdate` into `Operation`
166
+ @durable_execution
167
+ def place_order(event: dict, context: DurableContext) -> dict:
168
+ price = context.invoke("lookup-price", {"sku": event["sku"]}, name="price")
169
+ payment = context.invoke(
170
+ "process-payment", {"amount": price["price"]}, name="payment"
171
+ )
172
+ return {"sku": event["sku"], "charged": payment["charged"]}
173
+
174
+ def test_place_order_invokes_both_functions():
175
+ with DurableFunctionTestRunner(handler=place_order) as runner:
176
+ runner.register_durable_function(
177
+ "process-payment", process_payment, execution_timeout=60
178
+ )
179
+ runner.register_function("lookup-price", lookup_price)
180
+ result = runner.run(input='{"sku": "book-1"}')
181
+
182
+ assert result.result == '{"sku": "book-1", "charged": 25}'
183
+ assert result.get_invoke("payment").status.value == "SUCCEEDED"
184
+ ```
190
185
 
191
- ### 4. Observer Pattern Flow
192
- The observer pattern enables loose coupling between checkpoint processing and execution management:
186
+ ## Architecture
193
187
 
194
- 1. **CheckpointProcessor** processes operation updates
195
- 2. **Individual Processors** detect state changes (completion, failures, timer scheduling)
196
- 3. **ExecutionNotifier** broadcasts events to registered observers
197
- 4. **Executor** (as ExecutionObserver) receives notifications and updates **Execution** state
198
- 5. **Execution** complete_* methods finalize the execution state
188
+ See [docs/architecture.md](docs/architecture.md) for framework
189
+ internals. It covers the components, the worker model, the checkpoint
190
+ flow, pagination, and a map of the code.
199
191
 
200
192
 
201
193
  ## Documentation
@@ -220,4 +212,4 @@ tldr; use `hatch` and it will manage virtual envs and dependencies for you, so y
220
212
 
221
213
  ## License
222
214
 
223
- This project is licensed under the [Apache-2.0 License](LICENSE).
215
+ This project is licensed under the [Apache-2.0 License](https://github.com/aws/aws-durable-execution-sdk-python/blob/main/LICENSE).
@@ -0,0 +1,64 @@
1
+ aws_durable_execution_sdk_python_testing/__about__.py,sha256=PF_oYcM9RTUC3P846c3d27JU5o-gxm6cwcu_mFzcSDo,137
2
+ aws_durable_execution_sdk_python_testing/__init__.py,sha256=NJnSWv9wZndxH7C0lBDVyQ61uhT6i79m5Z_u-PJCVxg,578
3
+ aws_durable_execution_sdk_python_testing/child_dispatcher.py,sha256=BtTJMhrAv9LZRibE41VoWUyt8kp5wCSTH5MGO8VMBcg,31593
4
+ aws_durable_execution_sdk_python_testing/cli.py,sha256=Y-dy18C2wB_OauCQwih_zxP45h9z5NI7gv6zuMQirsU,21098
5
+ aws_durable_execution_sdk_python_testing/client.py,sha256=25BvIZPuWwuCJGYLZ931YIspgZeH1KRghkUG47lSHOA,2020
6
+ aws_durable_execution_sdk_python_testing/clock.py,sha256=Xoz9_fk8_wYfVl46WulfVqqPMIWgLu551_9CQaEh3vw,2295
7
+ aws_durable_execution_sdk_python_testing/exceptions.py,sha256=ftlWmR9bnNLdjR8ykm_yRW-fj5tQgVcNErO_yaTV3Ks,9627
8
+ aws_durable_execution_sdk_python_testing/execution.py,sha256=FI9IsmFGBzs7RLuv8NrUknm1RgIH0CfKfSwmhhIm_FQ,41094
9
+ aws_durable_execution_sdk_python_testing/executor.py,sha256=YxD2ph3OzrboxXnjFjrYA5Tsr4S67w_vPxoJ3cVDMIk,110585
10
+ aws_durable_execution_sdk_python_testing/invoker.py,sha256=FkEPT7m0PQIjGxIoJXtjZbFsqky814hvNw60epMj_g4,25862
11
+ aws_durable_execution_sdk_python_testing/model.py,sha256=4N_uPu71YJgf_YGYfcoVi8EaSWMInWuZpldJCvAEAD0,121777
12
+ aws_durable_execution_sdk_python_testing/observer.py,sha256=n0AGWgVGQ1-kZ2P8_YUq1vOC7UtooICm3KrTQVP_evk,5192
13
+ aws_durable_execution_sdk_python_testing/py.typed,sha256=DbCDcAirv769HS1ibzZLXq8VPazYf7JCkKSzj3ctudM,58
14
+ aws_durable_execution_sdk_python_testing/runner.py,sha256=qpTxgiq1UHM8r-_OiroCCbhTLaI1ANvfIhbCZwREXGk,58463
15
+ aws_durable_execution_sdk_python_testing/scheduler.py,sha256=tbXIQ8t34qq4BTBTRHZfXBybxFtPEhzX3222PWKtJKA,9645
16
+ aws_durable_execution_sdk_python_testing/threads.py,sha256=fzyOlc5oZyczZyAyW7vfYoR-g1XPm_bVdWvcSIP4H0M,5638
17
+ aws_durable_execution_sdk_python_testing/token.py,sha256=a4N84F1rfP6cyeafHHbnrG0UQalvg2dfVton8GD61AU,1714
18
+ aws_durable_execution_sdk_python_testing/checkpoint/__init__.py,sha256=sPmvbGOTRrDUvjiQwxsN8jS7uEQhpobt84yzYLEHfhk,81
19
+ aws_durable_execution_sdk_python_testing/checkpoint/core.py,sha256=j6a1I-TPUyJ-l3x1BNMQqEAi90WkPUui7mrya2RLFIU,6718
20
+ aws_durable_execution_sdk_python_testing/checkpoint/effects.py,sha256=-zaypUvWwh_hOmnFkMCX2KxoUqxSCkDvFOzXvJiAbNk,1592
21
+ aws_durable_execution_sdk_python_testing/checkpoint/processor.py,sha256=lf8wX2kMwSQzn_K8rH1d0q1uOH47jFXYLDsarVhQo7Q,6388
22
+ aws_durable_execution_sdk_python_testing/checkpoint/transformer.py,sha256=AsUmBsREhDLJccgjKS-l8jF4O_hJtQeOLMzh53ikPvY,7571
23
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/__init__.py,sha256=sArPe56rI4kIgaix8GuxQvg1SCIFKMr0YGGJ_wSGY6s,36
24
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/base.py,sha256=oeYJl0p7-lBhLPt1zU2jJ3cLKW2Pb5OgTq1A2lSNgQg,7859
25
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/callback.py,sha256=EQtLnYSBjXkBsfqdP74O7hmEcOnhzql25nstB5vUqTQ,3280
26
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/context.py,sha256=HW3bES9elkyM0Amx1M0Fk_lL11ACjJi2b81wqSa0oa4,2204
27
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/execution.py,sha256=7aZ3S0TOsXrhz6GU8L0FCuROiMaaanRjUkFne2sihts,1672
28
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/invoke.py,sha256=guVQmjcem9tn1c-0Or1GeEkvovD18iAovyZShsRRsiE,5672
29
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/step.py,sha256=8cAUSZd-Jg-Cn1mTJf_1spIoK3g_PXljdSJnn6LGN0A,4530
30
+ aws_durable_execution_sdk_python_testing/checkpoint/processors/wait.py,sha256=JxdMYYUZenMorSFUZXTeBs72Y4FOTTtm_tfXzDkQnqk,3198
31
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/__init__.py,sha256=odd1F9euptr28hqDh2Ux0Etcq_fPKBuYo0I1_wT6Pn8,36
32
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/checkpoint.py,sha256=nzKw6oDVmwgXQEXmqPFa1WU24x8yUOXiz-ntuSDcP0k,11993
33
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/__init__.py,sha256=VLB5L_4oMTa6baBv94moAjd-bsql8RfRdYDxitROm6g,37
34
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/callback.py,sha256=0EmQw7JDkbsxhV4y180QLJ0IxV2Zgf_6zjzlQ5gU0yE,1235
35
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/context.py,sha256=XF-3kwYdve26DctJp6_EZFInYy0z3Zu0FXbk5sb5PrU,2445
36
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/execution.py,sha256=tSt7MhfdxGNR1wddksS0ZzsqsxvMTZYXyd9oNOq6pgM,1426
37
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/invoke.py,sha256=UEovAdVK27J2e0PKXy1WZzxe_J1XKjhKAZixbFTFgEE,4406
38
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/step.py,sha256=H3QHVuf3zyMXwY8menTVWCjB5ndZEJEG_NB-THZzMjM,3564
39
+ aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/wait.py,sha256=E6m_upz1qQ6vQPOpU7mht0i_bBLLqfBP0UMYhGQG00k,1626
40
+ aws_durable_execution_sdk_python_testing/stores/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
41
+ aws_durable_execution_sdk_python_testing/stores/base.py,sha256=LdvwrhRgY8yCjxvnT1yZX6manFGzg_wmHwshnE8tWCg,5454
42
+ aws_durable_execution_sdk_python_testing/stores/filesystem.py,sha256=UZMWY3_mAcLlAb45lYHkBhhVbbC7IwkpgrjsFSoaLOM,3362
43
+ aws_durable_execution_sdk_python_testing/stores/memory.py,sha256=V9PQTU6r-EHUqWPRui8YnjvEpxnLKKJxvfteNK3kgBo,1076
44
+ aws_durable_execution_sdk_python_testing/stores/sqlite.py,sha256=FLa7P37Jiup3DtO2dn2x7J8bOVs9gSH-asU6XQC5g5U,11181
45
+ aws_durable_execution_sdk_python_testing/web/__init__.py,sha256=S8pemv1lfMXK4Kp8MIOAPEDMaUQGt9MArobCJhUERxw,84
46
+ aws_durable_execution_sdk_python_testing/web/errors.py,sha256=8elkOXggINFhmfRFSPqu3XvD0msiJ2gd5GD86o7pTQU,340
47
+ aws_durable_execution_sdk_python_testing/web/handlers.py,sha256=1qRoFJ4aGU21hfFBFFAdbt0dJ40SVxFJmLlGbN2pybA,30839
48
+ aws_durable_execution_sdk_python_testing/web/models.py,sha256=B4SKVcTculNsO4Qd53tqkPnwVxwguP5PjNgnWF7dp8o,8852
49
+ aws_durable_execution_sdk_python_testing/web/routes.py,sha256=NTHngxMDvsr78v_VjBXAf-tfwzm8P4o_DgiANJGwVuA,19935
50
+ aws_durable_execution_sdk_python_testing/web/serialization.py,sha256=urnP0-z6IB4V9dNEgNyxdFxaJybQbytiRaEj6LX1nK4,7775
51
+ aws_durable_execution_sdk_python_testing/web/server.py,sha256=aJ8vYZrBB_OnmR1o0D4n6AmI-eQk-xQgRXXYR12LNjY,8824
52
+ aws_durable_execution_sdk_python_testing/worker/__init__.py,sha256=PSR1N1yjPvSv63In2bYEn6CmJdTSLRI35lQ3x9bzvRw,416
53
+ aws_durable_execution_sdk_python_testing/worker/checkpoint_tasks.py,sha256=R-5FPboN20nfFpdCQrR9vwPayX6UEPOuF_PBF3gEjE8,3804
54
+ aws_durable_execution_sdk_python_testing/worker/execution_worker.py,sha256=d7PTpfWTz4hZJu2BmqYYYAdKCMwR1ewQV_I8H6N2J1Q,4245
55
+ aws_durable_execution_sdk_python_testing/worker/lane.py,sha256=O0bZ7cCwsKfxMAucCkkwC6iMYoUVc9eeoWtNNo1hnVI,4049
56
+ aws_durable_execution_sdk_python_testing/worker/registry.py,sha256=Vt5_DB9SaFA7uLEXbLcKq-QIheEfFs_JBDTwoNVvHOQ,4960
57
+ aws_durable_execution_sdk_python_testing/worker/status.py,sha256=NsML4saxud-6gm0dWAfzgFeelOshhqsT12rkA4ajQvs,929
58
+ aws_durable_execution_sdk_python_testing/worker/task.py,sha256=0X7Aiavo9EEB3GOElmzuIxyttmzrrJwrJRi_Wn89tXY,1740
59
+ aws_durable_execution_sdk_python_testing/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142
60
+ aws_durable_execution_sdk_python_testing/NOTICE,sha256=1CkO1kwu3Q_OHYTj-d-yiBJA_lNN73a4zSntavaD4oc,67
61
+ aws_durable_execution_sdk_python_testing-1.3.0.dist-info/METADATA,sha256=jwXr0cC25U3yfMou6Zde1dKROm3yHUHkexOKzhF-UHs,7777
62
+ aws_durable_execution_sdk_python_testing-1.3.0.dist-info/WHEEL,sha256=W3fkpkm7-wf9vBI5Z-7s0eWkeM-spu78I8Neb98DeEg,87
63
+ aws_durable_execution_sdk_python_testing-1.3.0.dist-info/entry_points.txt,sha256=fMm3DMHWb7k4-PSseaQ-BjUxNV_3Z7RyJaDVSwqnkEo,87
64
+ aws_durable_execution_sdk_python_testing-1.3.0.dist-info/RECORD,,
@@ -1,4 +1,4 @@
1
1
  Wheel-Version: 1.0
2
- Generator: hatchling 1.29.0
2
+ Generator: hatchling 1.32.4
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
@@ -1,66 +0,0 @@
1
- """Validator for valid actions by operation type."""
2
-
3
- from __future__ import annotations
4
-
5
- from typing import ClassVar
6
-
7
- from aws_durable_execution_sdk_python.lambda_service import (
8
- OperationAction,
9
- OperationType,
10
- )
11
-
12
- from aws_durable_execution_sdk_python_testing.checkpoint.validators.operations.callback import (
13
- VALID_ACTIONS_FOR_CALLBACK,
14
- )
15
- from aws_durable_execution_sdk_python_testing.checkpoint.validators.operations.context import (
16
- VALID_ACTIONS_FOR_CONTEXT,
17
- )
18
- from aws_durable_execution_sdk_python_testing.checkpoint.validators.operations.execution import (
19
- VALID_ACTIONS_FOR_EXECUTION,
20
- )
21
- from aws_durable_execution_sdk_python_testing.checkpoint.validators.operations.invoke import (
22
- VALID_ACTIONS_FOR_INVOKE,
23
- )
24
- from aws_durable_execution_sdk_python_testing.checkpoint.validators.operations.step import (
25
- VALID_ACTIONS_FOR_STEP,
26
- )
27
- from aws_durable_execution_sdk_python_testing.checkpoint.validators.operations.wait import (
28
- VALID_ACTIONS_FOR_WAIT,
29
- )
30
- from aws_durable_execution_sdk_python_testing.exceptions import (
31
- InvalidParameterValueException,
32
- )
33
-
34
-
35
- class ValidActionsByOperationTypeValidator:
36
- """Validates that the given action is valid for the given operation type."""
37
-
38
- _VALID_ACTIONS_BY_OPERATION_TYPE: ClassVar[
39
- dict[OperationType, frozenset[OperationAction]]
40
- ] = {
41
- OperationType.STEP: VALID_ACTIONS_FOR_STEP,
42
- OperationType.CONTEXT: VALID_ACTIONS_FOR_CONTEXT,
43
- OperationType.WAIT: VALID_ACTIONS_FOR_WAIT,
44
- OperationType.CALLBACK: VALID_ACTIONS_FOR_CALLBACK,
45
- OperationType.CHAINED_INVOKE: VALID_ACTIONS_FOR_INVOKE,
46
- OperationType.EXECUTION: VALID_ACTIONS_FOR_EXECUTION,
47
- }
48
-
49
- @staticmethod
50
- def validate(operation_type: OperationType, action: OperationAction) -> None:
51
- """Validate that the action is valid for the operation type."""
52
- valid_actions = (
53
- ValidActionsByOperationTypeValidator._VALID_ACTIONS_BY_OPERATION_TYPE.get(
54
- operation_type
55
- )
56
- )
57
-
58
- if valid_actions is None:
59
- msg_unknown_op: str = "Unknown operation type."
60
-
61
- raise InvalidParameterValueException(msg_unknown_op)
62
-
63
- if action not in valid_actions:
64
- msg_invalid_action: str = "Invalid action for the given operation type."
65
-
66
- raise InvalidParameterValueException(msg_invalid_action)
@@ -1,52 +0,0 @@
1
- aws_durable_execution_sdk_python_testing/__about__.py,sha256=PQWEqzylLD2U820VkLCmyPiye8vT-M9dJyxj5VqLjsM,137
2
- aws_durable_execution_sdk_python_testing/__init__.py,sha256=NJnSWv9wZndxH7C0lBDVyQ61uhT6i79m5Z_u-PJCVxg,578
3
- aws_durable_execution_sdk_python_testing/cli.py,sha256=LvduQB2oipKvuaJclIU3eQ806G0Gq5djVQlKPp0QpOg,18960
4
- aws_durable_execution_sdk_python_testing/client.py,sha256=1CFuUXBZIkM7YOWwlJu4OrcjrJSTk01-Zc3N75kYSR4,1682
5
- aws_durable_execution_sdk_python_testing/exceptions.py,sha256=ZgFPDtKgBn4-tj7fqaye901CksNQWL9RmMhgJBhEu_U,9110
6
- aws_durable_execution_sdk_python_testing/execution.py,sha256=QmnuC4dv42pbPY3babT3VhOndUBeKcJ6urvMo6griRc,17581
7
- aws_durable_execution_sdk_python_testing/executor.py,sha256=Q0ktkPa8OUUX8ky8pujmUfiiIRNyMIEPCagqdmOw008,48594
8
- aws_durable_execution_sdk_python_testing/invoker.py,sha256=Glx9ZN9hRRO_94Skb_qp95Y-DYCdTOfRapmt_KJ5uaU,13494
9
- aws_durable_execution_sdk_python_testing/model.py,sha256=xS6kHPEo4RdHph_rN8dVpQxZC0XzZJpYRLtbABe3A_U,121291
10
- aws_durable_execution_sdk_python_testing/observer.py,sha256=32MOYOfrmlKRqbfTXTM7m22iT38U2oYLGUkp7ar4Kvw,4935
11
- aws_durable_execution_sdk_python_testing/py.typed,sha256=DbCDcAirv769HS1ibzZLXq8VPazYf7JCkKSzj3ctudM,58
12
- aws_durable_execution_sdk_python_testing/runner.py,sha256=RKjttyO-hb4o_JPvlpiXYi_2Znk6yAfrFN4zJ0vKyrY,42512
13
- aws_durable_execution_sdk_python_testing/scheduler.py,sha256=yqKGu8r3OoqPaERpILVNCIwjhFRxGOKxk5u2QJyF-44,8551
14
- aws_durable_execution_sdk_python_testing/token.py,sha256=5rUpWMMcfZUVdOX_ptukRYiIRDsOdUA7faHXNyDGJRU,1530
15
- aws_durable_execution_sdk_python_testing/checkpoint/__init__.py,sha256=sPmvbGOTRrDUvjiQwxsN8jS7uEQhpobt84yzYLEHfhk,81
16
- aws_durable_execution_sdk_python_testing/checkpoint/processor.py,sha256=DeAGshP6OqFC4OTk334gvJHX2u_NV2X8qFEtZMnLeuI,3809
17
- aws_durable_execution_sdk_python_testing/checkpoint/transformer.py,sha256=7ea6avnyraOzZwO-aJOGUxtLK2WN95SuMDQ54UGPRus,3750
18
- aws_durable_execution_sdk_python_testing/checkpoint/processors/__init__.py,sha256=sArPe56rI4kIgaix8GuxQvg1SCIFKMr0YGGJ_wSGY6s,36
19
- aws_durable_execution_sdk_python_testing/checkpoint/processors/base.py,sha256=wHY9yD8l-lvFcmFUUDuyymFHYUrQet9svx7nTTyDeAs,7111
20
- aws_durable_execution_sdk_python_testing/checkpoint/processors/callback.py,sha256=iTG7LXvxjvu6I1OkmfHSn8y0gEFA0ymjl-q6M8IG4fM,3200
21
- aws_durable_execution_sdk_python_testing/checkpoint/processors/context.py,sha256=2uYcfHl12914-YAwJXFdOmkXORJc5rt39VHzOay7Hw0,2059
22
- aws_durable_execution_sdk_python_testing/checkpoint/processors/execution.py,sha256=mxQbBx7QiPD41kDvfC1ekz-36V0QUSMsmAd5GvnEjv4,1894
23
- aws_durable_execution_sdk_python_testing/checkpoint/processors/step.py,sha256=Fc8scYwa4Iz6wPWjkx9nMKA-HeozsNt4rvDu2P5lNys,4760
24
- aws_durable_execution_sdk_python_testing/checkpoint/processors/wait.py,sha256=hLS6ssHO-39ENkCzQdp5BpUz5pZFM_rAeHMKpuPFVXU,3442
25
- aws_durable_execution_sdk_python_testing/checkpoint/validators/__init__.py,sha256=odd1F9euptr28hqDh2Ux0Etcq_fPKBuYo0I1_wT6Pn8,36
26
- aws_durable_execution_sdk_python_testing/checkpoint/validators/checkpoint.py,sha256=1IFPKqlrSKek4t8NiLh-_-ydqRj3LwW51Ja1UvShsAQ,9538
27
- aws_durable_execution_sdk_python_testing/checkpoint/validators/transitions.py,sha256=ar9vAZU8ULs9ebs-ptd-6f-fPHPNzEOY6DtaNLVbOlE,2388
28
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/__init__.py,sha256=VLB5L_4oMTa6baBv94moAjd-bsql8RfRdYDxitROm6g,37
29
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/callback.py,sha256=0EmQw7JDkbsxhV4y180QLJ0IxV2Zgf_6zjzlQ5gU0yE,1235
30
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/context.py,sha256=XF-3kwYdve26DctJp6_EZFInYy0z3Zu0FXbk5sb5PrU,2445
31
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/execution.py,sha256=tSt7MhfdxGNR1wddksS0ZzsqsxvMTZYXyd9oNOq6pgM,1426
32
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/invoke.py,sha256=Henq9AsryTHeXRLoznSwKX1lmJvFrDC-FXNFX6RBj3Q,1720
33
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/step.py,sha256=H3QHVuf3zyMXwY8menTVWCjB5ndZEJEG_NB-THZzMjM,3564
34
- aws_durable_execution_sdk_python_testing/checkpoint/validators/operations/wait.py,sha256=E6m_upz1qQ6vQPOpU7mht0i_bBLLqfBP0UMYhGQG00k,1626
35
- aws_durable_execution_sdk_python_testing/stores/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
36
- aws_durable_execution_sdk_python_testing/stores/base.py,sha256=LdvwrhRgY8yCjxvnT1yZX6manFGzg_wmHwshnE8tWCg,5454
37
- aws_durable_execution_sdk_python_testing/stores/filesystem.py,sha256=o9DJ18bThSl1QUpfR3nE_BffLHchslePpz2VxrvLrJI,2910
38
- aws_durable_execution_sdk_python_testing/stores/memory.py,sha256=V9PQTU6r-EHUqWPRui8YnjvEpxnLKKJxvfteNK3kgBo,1076
39
- aws_durable_execution_sdk_python_testing/stores/sqlite.py,sha256=QvMY_BUyg3FAYNDzqQz7BMseGmCTlRLlPa0r02JYvMc,10822
40
- aws_durable_execution_sdk_python_testing/web/__init__.py,sha256=S8pemv1lfMXK4Kp8MIOAPEDMaUQGt9MArobCJhUERxw,84
41
- aws_durable_execution_sdk_python_testing/web/errors.py,sha256=8elkOXggINFhmfRFSPqu3XvD0msiJ2gd5GD86o7pTQU,340
42
- aws_durable_execution_sdk_python_testing/web/handlers.py,sha256=5_r6zaoaPujnNJohXQ_iPbXJJCR7vPMJfDT_fXr-VjI,29523
43
- aws_durable_execution_sdk_python_testing/web/models.py,sha256=B4SKVcTculNsO4Qd53tqkPnwVxwguP5PjNgnWF7dp8o,8852
44
- aws_durable_execution_sdk_python_testing/web/routes.py,sha256=AU9fMhuR0HF9fltNZ6TZMNOueQc8wEeNyJqoBpMctm0,19466
45
- aws_durable_execution_sdk_python_testing/web/serialization.py,sha256=qN6qJNgEYVqRQD9uhHupJVxyZfz4sc8KzIwxEqVIEcI,7747
46
- aws_durable_execution_sdk_python_testing/web/server.py,sha256=DQWwgyb_GKkHbFw_OYgPG1o7uIZ4-sG7F-GAUclLYu0,8853
47
- aws_durable_execution_sdk_python_testing-1.2.0.dist-info/METADATA,sha256=IuDBlYasIDs1Ijs1qnaYMAQ82-Dv1aQKYIYKXUZc0Oc,8921
48
- aws_durable_execution_sdk_python_testing-1.2.0.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87
49
- aws_durable_execution_sdk_python_testing-1.2.0.dist-info/entry_points.txt,sha256=fMm3DMHWb7k4-PSseaQ-BjUxNV_3Z7RyJaDVSwqnkEo,87
50
- aws_durable_execution_sdk_python_testing-1.2.0.dist-info/licenses/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142
51
- aws_durable_execution_sdk_python_testing-1.2.0.dist-info/licenses/NOTICE,sha256=1CkO1kwu3Q_OHYTj-d-yiBJA_lNN73a4zSntavaD4oc,67
52
- aws_durable_execution_sdk_python_testing-1.2.0.dist-info/RECORD,,