Skip to content
PACKAGES

operators.first

Kind: function

Source: src/graphrefly/operators/_select.py:199

first(g: Graph, src: Node[Any], p: Predicate | None = None, *, name: str | None = None, recipe: Recipe | None = None)

Send the first DATA, or the first for which p holds, and complete in the same array; a source that completes without one completes first without DATA (O-first).

The behavior is the root’s operator contract: the operator contracts.