batch_by_property
from noon import batch_by_property
Source-derived function. Host availability is not inferred from this listing. See reference scope.
batch_by_property(items: Iterable[T], property_func: Callable[[T], U]) -> list[tuple[list[T], U | None]]
| Parameter | Kind | Annotation | Default |
|---|---|---|---|
items | positional or keyword | Iterable[T] | No default |
property_func | positional or keyword | Callable[[T], U] | No default |
Return annotation: list[tuple[list[T], U | None]]
Group adjacent user values by their callback result, retaining order.