function

pipeline.walk_swap

def walk_swap(root: object, registry: SoftRegistry) -> object

Replace nodes in the stage tree by structural recursion.

Uses :func:`dataclasses.replace` to preserve frozen-dataclass immutability.

Parameters

NameTypeDescription
rootobjectStage-tree root.
registrySoftRegistryHard-to-soft factory table.

Returns

object — New root with all replaceable nodes swapped.

Source: unitrack/pipeline/diff.py:191