from __future__ import annotations

from graph.exploration.algorithms.in_memory.graph_features.common import FeatureRowsByKey


def apply_degree(rows_by_key: FeatureRowsByKey, degree_by_key: dict[object, int]) -> None:
    for node_key, value in degree_by_key.items():
        rows_by_key[node_key]["degree"] = int(value)
