langchain-ai/langgraph · error · ValueError
Text fields must be a list or a string. Got {text_fields}
Error message
Text fields must be a list or a string. Got {text_fields} What it means
Error "Text fields must be a list or a string. Got {text_fields}" thrown in langchain-ai/langgraph.
Source
Thrown at libs/checkpoint-sqlite/langgraph/store/sqlite/base.py:1497
"""
raise NotImplementedError(_AIO_ERROR_MSG)
# Helper functions
def _ensure_index_config(
index_config: SqliteIndexConfig,
) -> tuple[Any, SqliteIndexConfig]:
"""Process and validate index configuration."""
index_config = index_config.copy()
tokenized: list[tuple[str, Literal["$"] | list[str]]] = []
tot = 0
text_fields = index_config.get("text_fields") or ["$"]
if isinstance(text_fields, str):
text_fields = [text_fields]
if not isinstance(text_fields, list):
raise ValueError(f"Text fields must be a list or a string. Got {text_fields}")
for p in text_fields:
if p == "$":
tokenized.append((p, "$"))
tot += 1
else:
toks = tokenize_path(p)
tokenized.append((p, toks))
tot += len(toks)
index_config["__tokenized_fields"] = tokenized
index_config["__estimated_num_vectors"] = tot
embeddings = ensure_embeddings(
index_config.get("embed"),
)
return embeddings, index_config
_PLACEHOLDER = object()
View on GitHub (pinned to 38031739e5)
When it happens
Trigger: Thrown at libs/checkpoint-sqlite/langgraph/store/sqlite/base.py:1497 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/6da0e92c46176414.
Report an issue: GitHub.