langchain-ai/langgraph · error · ValueError
snapshot_frequency must be a positive int, got {snapshot_fre
Error message
snapshot_frequency must be a positive int, got {snapshot_frequency} What it means
Error "snapshot_frequency must be a positive int, got {snapshot_frequency}" thrown in langchain-ai/langgraph.
Source
Thrown at libs/langgraph/langgraph/channels/delta.py:77
and batching-invariant as described above.
typ: The value type (e.g. `list`, `dict`). Inferred automatically
from the outer type when used inside `Annotated[T, DeltaChannel(...)]`.
snapshot_frequency: Every Nth update to this channel writes a snapshot
blob (default `1000`). Must be a positive int.
"""
__slots__ = ("value", "reducer", "snapshot_frequency")
value: Value | Any
def __init__(
self,
reducer: Callable[[Any, Sequence[Any]], Any],
typ: type[Value] | None = None,
*,
snapshot_frequency: int = 1000,
) -> None:
if snapshot_frequency <= 0:
raise ValueError(
f"snapshot_frequency must be a positive int, got {snapshot_frequency}"
)
if typ is None:
typ = list # type: ignore[assignment] # placeholder; overridden by _is_field_channel
super().__init__(typ)
self.reducer = reducer
self.snapshot_frequency = snapshot_frequency
typ = _strip_extras(typ)
if typ in (collections.abc.Sequence, collections.abc.MutableSequence):
typ = list
if typ in (collections.abc.Set, collections.abc.MutableSet):
typ = set
if typ in (collections.abc.Mapping, collections.abc.MutableMapping):
typ = dict
self.typ = typ
self.value: Any = MISSING
def __eq__(self, other: object) -> bool:View on GitHub (pinned to 38031739e5)
When it happens
Trigger: Thrown at libs/langgraph/langgraph/channels/delta.py:77 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of langchain-ai/langgraph@38031739e5 (2026-08-26).
Data as JSON: /api/errors/8d59f8aa5cb602e6.
Report an issue: GitHub.