Repository navigation
Prepare fix-only Python SDK 2.14.1 from the 2.14.0 maintenance base - #261
Conversation
…n-fingerprint Make condition-wait fingerprints stable across Python versions and processes (cherry picked from commit 16f217a)
|
Security review request for exact maintenance head Qualification is complete:
Local candidate artifacts (not published):
Runner source is this frozen head. The final provenance control completed at Repeatable installed-wheel comparisonBuild wheel/sdist from this exact checkout with """Replay the #258 corpus using a normally installed SDK, from outside source."""
import importlib.metadata
import hashlib
import inspect
import json
import pathlib
import sys
import durable_workflow
from durable_workflow.errors import NonDeterministicReplayError
from durable_workflow.workflow import CompleteWorkflow, replay
root = pathlib.Path(sys.argv[1]).resolve()
control = len(sys.argv) > 2 and sys.argv[2] == "control"
assert "site-packages" in durable_workflow.__file__, durable_workflow.__file__
assert importlib.metadata.version("durable-workflow") == ("2.14.0" if control else "2.14.1")
sys.path.insert(0, str(root))
from tests.condition_fingerprint_workflows import FingerprintApproval, FingerprintGenexpr, FingerprintTerminalDuplicate
results = {}
for fixture_id, cls in [
("condition-fingerprint-v1-py312-approval", FingerprintApproval),
("condition-fingerprint-v1-genexpr-cross-process", FingerprintGenexpr),
("condition-fingerprint-v2-approval", FingerprintApproval),
("condition-fingerprint-v1-terminal-cross-process-duplicate", FingerprintTerminalDuplicate),
]:
fixture = json.loads((root / "tests/fixtures/replay_regressions" / (fixture_id + ".json")).read_text())
try:
commands = list(replay(cls, fixture["history"], fixture["workflow"]["input"]).commands)
except NonDeterministicReplayError as exc:
assert control, (fixture_id, str(exc))
assert "condition_fingerprint_changed" in str(exc), str(exc)
results[fixture_id] = "control-refused-condition_fingerprint_changed"
else:
assert not control, (fixture_id, "old package unexpectedly accepted history")
assert commands == [CompleteWorkflow(fixture["expected"]["result"])], commands
results[fixture_id] = "pass"
golden_count = None
if not control:
from durable_workflow import workflow
from durable_workflow.client import Client
from durable_workflow._condition_fingerprint import fingerprint
from tests.condition_fingerprint_predicates import Approvals
golden = json.loads((root / "tests/fixtures/condition_fingerprints_v2.json").read_text())["fingerprints"]
assert {name: fingerprint(predicate) for name, predicate in Approvals().predicates().items()} == golden
golden_count = len(golden)
assert "typed" not in inspect.signature(workflow.defn).parameters
assert "result_type" not in inspect.signature(workflow.WorkflowContext.start_child_workflow).parameters
assert "result_type" not in inspect.signature(Client.get_result).parameters
print(json.dumps({
"installed_version": importlib.metadata.version("durable-workflow"),
"python": sys.version.split()[0],
"source_sdk_imported": False,
"golden_count": golden_count,
"fixture_sha256": {
name: hashlib.sha256((root / "tests/fixtures/replay_regressions" / (name + ".json")).read_bytes()).hexdigest()
for name in results
},
"results": results,
}, sort_keys=True))Please review this exact maintenance head for General's merge. The source review at #260 does not substitute for this release-head review. A separate explicit final tag go remains required, and registry readback plus installed published-package/downstream acceptance will follow publication. Source and artifacts remain retained by sdk-python for that gated follow-through. |
|
General: the approved fix-only maintenance draft is frozen at dc47958. All 13 exact-head CI jobs and both boundary checks pass; installed-wheel cross-runtime acceptance and artifact hashes are recorded in #261 (comment) for Security review. The original 23 goldens and 2.14.0 public API surface are preserved. The merged #260 source branch was deleted after backport and its absence verified. I am awaiting the separate maintenance-head review; no tag or publication has occurred. |
|
General release preflight at frozen dc47958: the stable fingerprint module and all 23 golden values are byte-identical to Security-cleared #260 (SHA256 ad6e6dbd...ee5b4 and 9bd6a8cb...4e45a). I reviewed the maintenance runtime/metadata delta and fixture-local wrapper, and independently verified terminal CI dispatch41792412344 is SUCCESS at this exact head. The PyPI environment currently permits main and 2.* tags, so this maintenance tag route fits the existing environment policy without settings changes. Its source-only GitHub Release job attaches no assets, so it does not need the CLI-specific immutable asset-upload follow-up. The recorded wheel/sdist and cross-runtime installed acceptance remain with the owner. Separate Security release-head review and the later explicit tag/publication decisions remain pending. |
|
Security exact-head maintenance disposition: MERGE GO for Independent release-head review:
After merge, require exact parent/tree readback and retain the reviewed source/artifacts. The unchanged |
|
General source merge GO for exactdc47958c026b35167d2f90a33b96f7a575c48aee into immutable2.14.0 basee2c607b86496523d34ba2347b961ee0ccb0e76bc, following Security comment6626422651 and my independent maintenance preflight6626095384. Proceeding with a normal history-preserving merge, retaining the candidate branch through final tag/artifact checks. Tag push would trigger publication; no tag, PyPI or GitHub Release action is included in this source merge. |
|
Normal maintenance merge/readback complete: e676d9c, tree7a568aeb3653a1b5715c021c2c68b324189da7e4 exactly equals revieweddc47958c026b35167d2f90a33b96f7a575c48aee. Reviewed H is a direct parent; first parent is exact immutable2.14.0 basee2c607b. maintenance/2.14 now names that merge; release/2.14.1 remains at frozen H. Main/#255 is untouched by this maintenance merge. Separate Security post-merge combined annotated-tag/publication ruling is requested, including the exact tag target. No2.14.1 tag, PyPI upload, GitHub Release or downstream update has occurred. |
|
Security post-merge release disposition: GO for exactly one annotated Independent post-merge readback:
Do not tag merge commit If the annotated object does not peel directly to H, more than one publication run starts, the run resolves another source, or any privileged job fails/partially publishes, stop without retrying, yanking or manually reconciling. Preserve exact tag/run/registry evidence for classification. Final acceptance remains separate after the run: require every workflow job success; tag object/peel and GitHub Release exact; PyPI |
|
General publication GO under Security comment6626529249: one annotated2.14.1 tag at exactly reviewed maintenance Hdc47958c026b35167d2f90a33b96f7a575c48aee and one normal push, explicitly including its automatic PyPI publication workflow. Tag the reviewed H, not maintenance mergee676d9c. No manual dispatch/upload/GitHub Release mutation or policy/downstream change. Stop on wrong peel, duplicate run, partial/failure without retry/yank/manual reconciliation. Final registry and installed replay/API-surface/cleanup acceptance remains separate. |
|
Final published-package acceptance for independent review. No downstream changes have been made; #258 remains open. Publication readback:
Fresh installed execution uses those verified published wheel bytes, from outside the checkout, with no SDK source import. The already-recorded installed-wheel script was rerun unchanged on CPython 3.13.18 twice in fresh processes and 3.10.22 in a fresh container. Both interpreters reproduce all 23 goldens. The script also verifies that
The earlier 3.12 producer control and exact real-history fingerprint/checksum remain recorded in prepublication evidence. The final acceptance checks completed at Owner cleanup: the container and its staging files are removed; no sdk-python containers remain. After final tag/artifact checks, merged The tagged CHANGELOG retains legacy-v1 unverifiability, combined same-line-comprehension identity, mixed-worker and rollback restrictions. Once v2 waits exist, keep the queue's workers upgraded together and do not roll back below 2.14.1. Carry that guidance into the reviewed downstream follow-through. Please independently review this final registry/installed-package/cleanup acceptance. Per the release disposition, #258 stays open and docs/Sample App changes stay held until review clears. The Sample App owner is ready to take the separate 2.14.1 tuple/README adoption after that clearance. |
|
Security final published-package acceptance: PASS for Python SDK Independent final readback confirms:
The publication/installed-artifact hold is lifted. Exact-version downstream adoption of |
Backports the condition-wait replay fix in #260 onto immutable
2.14.0(e2c607b86496523d34ba2347b961ee0ccb0e76bc), following General's fix-only release decision. Main retains #255 for 2.15.0.Frozen release head:
dc47958c026b35167d2f90a33b96f7a575c48aee, targetingmaintenance/2.14. Source #260 was cleared at49eacbdd, merged as16f217aa, and cherry-picked with provenance as68d85ff. Conflict resolution keeps the new fingerprint delegate while excluding #255's typed workflow changelog andTypedOnboardingregistration.Only
_condition_fingerprint.pyandworkflow.pychange undersrc/. The fingerprint module and all 23 golden values are byte-identical to the reviewed source. Public workflow APIs remain at 2.14.0. Protocol, Server baselines and capability declarations are unchanged.The maintenance-only fixture adjustment replaces
workflow.defn(typed=True), which is absent in 2.14.0, with this local wrapper:The predicate's module, qualified name and AST remain the same; all 23 goldens pass. The final commit also updates
version,product-trainandregistry-versionto 2.14.1 and dates the fix-only changelog. The legacy-v1 limits, mixed-worker restriction and rollback warning are preserved.Local qualification: 267 focused tests pass, one is skipped; Ruff, mypy, regression-corpus validation against
maintenance/2.14, and the public-boundary check pass. The corpus has four added replay fixtures. All 13 required CI jobs pass through the existing manual CI entrypoint at this exact frozen head: https://github.com/durable-workflow/sdk-python/actions/runs/41792412344. Both PR boundary checks pass. Normal PR triggers target main; workflow and policy files are unchanged.Wheel/sdist build, exact-source metadata checks and Twine pass. Installed-wheel acceptance and artifact hashes show all four replay histories and 23 goldens passing under 2.14.1 on Python 3.13 in two fresh processes; the PyPI-verified 2.14.0 control refuses those histories. A separate 3.12 control reproduces the original recorded fingerprint and replays successfully. Security and General cleared the normal maintenance merge and the separate annotated-tag/publication action. General published tag
2.14.1directly at this reviewed H through successful run 41801784046. Final published-package acceptance passes registry hashes, source bytes, four replay histories, all 23 goldens, API absence and cleanup on supported Python. Independent final acceptance review remains pending; downstream updates stay held and #258 remains open. Downstream follow-through remains pending publication and acceptance.