MemPalace/mempalace · error · ValueError
row {idx}: id must be a non-empty string
Error message
row {idx}: id must be a non-empty string What it means
Error "row {idx}: id must be a non-empty string" thrown in MemPalace/mempalace.
Source
Thrown at mempalace/backends/milvus.py:507
raise ValueError(
f"documents length {len(documents)} does not match ids length {len(ids)}"
)
if metadatas is not None and len(metadatas) != len(ids):
raise ValueError(
f"metadatas length {len(metadatas)} does not match ids length {len(ids)}"
)
if len(embeddings) != len(ids):
raise ValueError(
f"embeddings length {len(embeddings)} does not match ids length {len(ids)}"
)
vectors, dimension = _normalize_vectors(embeddings)
metadatas = metadatas or [{} for _ in ids]
rows = []
for idx, (doc_id, document, metadata, vector) in enumerate(
zip(ids, documents, metadatas, vectors)
):
if not isinstance(doc_id, str) or not doc_id:
raise ValueError(f"row {idx}: id must be a non-empty string")
doc_id_bytes = _utf8_len(doc_id)
if doc_id_bytes > DRAWER_ID_MAX_LENGTH:
raise ValueError(
f"row {idx}: id byte length {doc_id_bytes} exceeds {DRAWER_ID_MAX_LENGTH}"
)
document = _clean_text(document)
document_bytes = _utf8_len(document)
if document_bytes > DOCUMENT_MAX_LENGTH:
raise ValueError(
f"row {idx}: document byte length {document_bytes} exceeds "
f"Milvus VARCHAR limit {DOCUMENT_MAX_LENGTH}; chunk before storing"
)
row = {
FIELD_ID: doc_id,
FIELD_DOCUMENT: document,
FIELD_METADATA: _jsonable_metadata(metadata),
FIELD_VECTOR: vector,
}View on GitHub (pinned to 06cb6987f0)
Solutions
- Ensure every drawer id is a non-empty string before calling add/update
When it happens
Trigger: Thrown at mempalace/backends/milvus.py:507 when the library encounters an invalid state.
Common situations: Upstream miner or chunker emitted an empty or non-string drawer id.
AI-assisted analysis of MemPalace/mempalace@06cb6987f0 (2026-08-15).
Data as JSON: /api/errors/291f08706697cd81.
Report an issue: GitHub.