DependencyGraph.set_node_metadata()

Replace a node’s metadata mapping durably.

Usage

Source

DependencyGraph.set_node_metadata(
    key,
    metadata,
)

The provided mapping is copied; subsequent mutations to the caller’s object do not affect graph state. Raises KeyError if the node is missing.