Repository navigation
Use persisted workflow-start clocks during cold replay - #147
Conversation
|
Reviewed the persisted-clock implementation and minimal corpus case. The exact source tree The private stable candidate also passes159 installed clock/corpus/marker controls, including the formerly plugin-blocked asynchronous cases. Two fresh interpreter executions on the unchanged genuine PHP bridge wire produce identical original-start clocks and UUIDv7 with exact typed values. Explicit payload timestamp precedence/offsets and deterministic refusal of missing or malformed persisted time remain intact. Partial marker-only histories can still replay without accessing a clock. This preserves Python's fixed start-clock model. Merging the source correction. Independent stable148 still requires its full CI, connected worker consumers and normal publication/installed verification; no published2.5.13 claim yet. |
Actual supported Workflow bridge histories omit
WorkflowStarted.payload.timestamp, so Python currently falls back to wall time and returns differentctx.now()values on identical cold reads. This seeds the fixed workflow-start clock from canonicalrecorded_atwhen the optional explicit timestamp is absent, preserving explicit timestamp precedence and making UUIDv7 use the same validated clock.Clock-dependent replay reports missing or invalid persisted time rather than using wall time. Empty local authoring and marker-only partial histories retain their existing use; marker clocks, original histories and the shared reader are unchanged.
Adds a minimal replay-corpus reproduction and controls for repeated cold reads, marker boundaries, explicit precedence, malformed/missing timestamps and UUIDv7. Validation: 310 focused source checks, Ruff and mypy pass. Normally installed 2.5.12 fails all 27 new regressions while passing both compatibility controls. Source CI, exact stable backport and normally installed consumer qualification remain required. This preserves Python's workflow-start clock contract and makes no PHP per-command clock-parity claim.
Refs #146.