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
7 changes: 5 additions & 2 deletions .github/tests/otel_legacy_registration_rejection_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
"""Verify the factory migration boundary against a real installed OTel 1 wheel."""
"""Verify the factory migration boundary against a real installed OTel 1 wheel.

Run with ``hatch run test-wheel-otel-legacy:test``. Its installer verifies the
current core artifact; OTel 1.0.0 is the fixed legacy compatibility fixture.
"""

from importlib.metadata import version
from pathlib import Path
Expand Down Expand Up @@ -30,7 +34,6 @@
def test_installed_legacy_registration_fails_before_invocation(
monkeypatch: pytest.MonkeyPatch, view, name: str, registration: str
) -> None:
assert version("aws-durable-execution-sdk-python") == "3.0.1"
Comment thread
zhongkechen marked this conversation as resolved.
Resolved
assert version("aws-durable-execution-sdk-python-otel") == "1.0.0"
assert "site-packages" in Path(core_execution.__file__).resolve().parts
assert "site-packages" in Path(installed_otel.__file__).resolve().parts
Expand Down
10 changes: 5 additions & 5 deletions .github/tests/otel_lifecycle_compatibility_test.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
"""Exercise real installed version pairs through the public durable handler."""
"""Exercise installed wheels through the public durable handler.

Run with ``hatch run test-wheel-otel:test``. Its installer selects the current
versions from __about__.py and verifies wheel hashes and installed source bytes.
"""

from __future__ import annotations

import contextvars
from datetime import UTC, datetime
from importlib.metadata import version
from pathlib import Path
import threading
from types import SimpleNamespace
Expand All @@ -28,7 +31,6 @@
from opentelemetry.sdk.trace import TracerProvider
from opentelemetry.sdk.trace.export import SimpleSpanProcessor
from opentelemetry.sdk.trace.export.in_memory_span_exporter import InMemorySpanExporter
from packaging.version import Version


class NoNetworkClient:
Expand All @@ -42,8 +44,6 @@ def __getattr__(self, name: str):
@pytest.mark.parametrize("order", ["alone", "baggage-first", "baggage-last"])
@pytest.mark.parametrize("ambient_present", [False, True])
def test_installed_factory_pair_preserves_worker_context(view, order, ambient_present):
assert Version(version("aws-durable-execution-sdk-python")) == Version("3.0.1")
assert version("aws-durable-execution-sdk-python-otel") == "2.0.0"
Comment thread
zhongkechen marked this conversation as resolved.
Resolved
assert "site-packages" in Path(core_execution.__file__).resolve().parts
import aws_durable_execution_sdk_python_otel as installed_otel

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ version = "0.0.0"
description = "OpenTelemetry conformance test handlers for the AWS Durable Execution SDK for Python, exercised by the aws-durable-execution-conformance-tests OTel suites."
requires-python = ">=3.11"
dependencies = [
"aws-durable-execution-sdk-python==3.0.1",
"aws-durable-execution-sdk-python-otel==2.0.0",
"aws-durable-execution-sdk-python==3.0.2",
"aws-durable-execution-sdk-python-otel==2.1.0",
]

[tool.hatch.build.targets.wheel]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ version = "0.0.0"
description = "Durable Execution Telemetry conformance test handlers for the AWS Durable Execution SDK for Python, exercised by the aws-durable-execution-conformance-tests telemetry suite."
requires-python = ">=3.11"
dependencies = [
"aws-durable-execution-sdk-python==3.0.1",
"aws-durable-execution-sdk-python==3.0.2",
"aws-durable-execution-sdk-python-telemetry-exporter==1.0.0",
]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ version = "0.0.0"
description = "Cross-SDK conformance test handlers for the AWS Durable Execution SDK for Python, exercised by the aws-durable-execution-conformance-tests runner."
requires-python = ">=3.11"
dependencies = [
"aws-durable-execution-sdk-python==3.0.1",
"aws-durable-execution-sdk-python==3.0.2",
]

[tool.hatch.build.targets.wheel]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2025-present Amazon.com, Inc. or its affiliates.
#
# SPDX-License-Identifier: Apache-2.0
__version__ = "2.0.0"
__version__ = "2.1.0"
3 changes: 3 additions & 0 deletions packages/aws-durable-execution-sdk-python-testing/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ Test Python durable functions locally, before you deploy them.
pip install aws-durable-execution-sdk-python-testing
```

Requires Core SDK 3.0.2 or later, which preserves empty errors when saved
execution state is reloaded.

## Quick start

```python
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ classifiers = [
]
dependencies = [
"boto3>=1.42.1",
"aws-durable-execution-sdk-python>=3.0.0",
# Core 3.0.2 preserves empty errors when saved execution state is reloaded.
"aws-durable-execution-sdk-python>=3.0.2",
]

[project.urls]
Expand Down Expand Up @@ -66,7 +67,7 @@ dependencies = [
"pytest",
"pytest-cov",
"ruff",
"aws-durable-execution-sdk-python>=3.0.0",
"aws-durable-execution-sdk-python>=3.0.2",
]

[tool.hatch.envs.test.scripts]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2025-present Amazon.com, Inc. or its affiliates.
#
# SPDX-License-Identifier: Apache-2.0
__version__ = "1.4.0"
__version__ = "1.4.1"
Comment thread
zhongkechen marked this conversation as resolved.
Resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
"""Protect the Core compatibility boundary for empty-error persistence."""

from pathlib import Path
import tomllib

from packaging.requirements import Requirement
import pytest


@pytest.mark.parametrize("dependency_source", ["runtime", "test"])
def test_core_dependency_requires_empty_error_preservation(
dependency_source: str,
) -> None:
package_root = Path(__file__).resolve().parents[1]
metadata = tomllib.loads((package_root / "pyproject.toml").read_text())
dependencies = {
"runtime": metadata["project"]["dependencies"],
"test": metadata["tool"]["hatch"]["envs"]["test"]["dependencies"],
}[dependency_source]
requirements = {
requirement.name: requirement for requirement in map(Requirement, dependencies)
}
core = requirements["aws-durable-execution-sdk-python"]

# These are fixed compatibility fixtures, not the current release versions.
# Core 3.0.1 loses empty errors on reload; Core 3.0.2 first preserves them.
assert not core.specifier.contains("3.0.1")
assert core.specifier.contains("3.0.2")
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: 2025-present Amazon.com, Inc. or its affiliates.
#
# SPDX-License-Identifier: Apache-2.0
__version__ = "3.0.1"
__version__ = "3.0.2"
Loading