replay
Replay planning utilities.
Translates Kitaru's unified replay override surface into ZenML replay inputs
consumed by Pipeline.replay(...) plus a small runtime context consumed by
Kitaru checkpoints during the live replay tail.
attributelogger= logging.getLogger(__name__)attributeREPLAY_SKIPPED_STEPS_METADATA_KEY= 'kitaru_replay_skipped_steps_v1'attributeREPLAY_RESERVED_KWARGS= frozenset({'at', 'flow_overrides', 'checkpoint_overrides', 'invocation_overrides', 'skip', 'tag', 'wait', 'on_error', 'stack', 'image', 'cache', 'retries'})attributeReplayAtStatus= Literal['present', 'missing', 'ambiguous', 'no_checkpoints']funcsafe_compare_url_for_executions(exec_ids) -> str | NoneBuild a compare URL without letting URL lookup break replay results.
paramexec_idsSequence[str]Returns
str | Nonefuncreplay_skipped_steps_metadata(steps_to_skip) -> dict[str, Any]Return deterministic replay skip metadata for an execution.
paramsteps_to_skipIterable[str]Returns
dict[str, typing.Any]funcparse_replay_skipped_steps_metadata(metadata) -> set[str]Parse replay skip evidence from execution metadata safely.
parammetadataMapping[str, Any]Returns
set[str]funcreplay_step_invocation_id(step) -> strReturn the invocation ID Kitaru uses when planning replay skips.
paramstepStepRunResponseReturns
strfuncsafe_persist_replay_submission_metadata(*, replay_exec_id, original_exec_id, submission_id, tag, steps_to_skip=None) -> NoneBest-effort replay correlation metadata and tag persistence.
paramreplay_exec_idstrparamoriginal_exec_idstrparamsubmission_idstrparamtagstr | Noneparamsteps_to_skipIterable[str] | None= NoneReturns
Nonefuncnew_replay_submission_id() -> strReturn a non-sensitive replay submission correlation ID.
Returns
strfuncreplay_at_status(*, run, at) -> ReplayAtStatusReturn whether at resolves for a source execution.
paramrunPipelineRunResponseparamatstrReturns
kitaru.replay.ReplayAtStatusfuncreplay_at_skip_reason(*, run, at) -> strReturn a human-readable skip/failure reason for a replay at selector.
paramrunPipelineRunResponseparamatstrReturns
strfuncbuild_replay_request_document(*, flow_overrides=None, checkpoint_overrides=None, invocation_overrides=None, skip=None) -> ReplayPlanDocumentValidate and serialize the public replay request shape.
paramflow_overridesMapping[str, Any] | None= Noneparamcheckpoint_overridesMapping[str, Any] | None= Noneparaminvocation_overridesMapping[str, Any] | None= NoneparamskipSequence[str] | None= NoneReturns
kitaru.replay.ReplayPlanDocumentfuncplan_requires_runtime_transport(plan) -> boolReturn whether this replay plan needs KITARU_REPLAY_CONTEXT transport.
paramplanReplayPlanReturns
boolfuncbuild_replay_plan(*, run, at, flow_overrides=None, checkpoint_overrides=None, invocation_overrides=None, skip=None) -> ReplayPlanBuild a replay plan for a completed or paused execution.
Checkpoints before at are skipped. at and its downstream descendants
re-execute unless an output override injects a value or skip asks to
play back a recorded result. Checkpoint-scope overrides intentionally fan
out to every matching invocation; invocation-scope overrides target exactly
one invocation/call ID and win over checkpoint-scope values.
paramrunPipelineRunResponseparamatstrparamflow_overridesMapping[str, Any] | None= Noneparamcheckpoint_overridesMapping[str, Any] | None= Noneparaminvocation_overridesMapping[str, Any] | None= NoneparamskipSequence[str] | None= NoneReturns
kitaru.replay.ReplayPlan