MemPalace/mempalace · error · ValueError
update requires at least one of documents, metadatas, embedd
Error message
update requires at least one of documents, metadatas, embeddings
What it means
An OSError from the local onboarding writer: mempalace.yaml already exists at the project root but is not a regular file (typically a FIFO). Opening a FIFO for writing blocks in the kernel until a reader appears, which would hang `init` with no output, so the code refuses up front.
Source
Thrown at mempalace/backends/chroma.py:1715
}
sanitized = self._sanitize_metadatas_for_chromadb(metadatas)
if sanitized is not None:
kwargs["metadatas"] = sanitized
if embeddings is not None:
kwargs["embeddings"] = embeddings
with self._write_lock():
self._collection.upsert(**kwargs)
def update(
self,
*,
ids,
documents=None,
metadatas=None,
embeddings=None,
):
if documents is None and metadatas is None and embeddings is None:
raise ValueError("update requires at least one of documents, metadatas, embeddings")
kwargs: dict[str, Any] = {"ids": ids}
if documents is not None:
kwargs["documents"] = self._sanitize_documents_for_chromadb(documents)
if metadatas is not None:
kwargs["metadatas"] = metadatas
if embeddings is not None:
kwargs["embeddings"] = embeddings
with self._write_lock():
self._collection.update(**kwargs)
# ------------------------------------------------------------------
# Reads
# ------------------------------------------------------------------
def query(
self,
*,
query_texts=None,View on GitHub (pinned to 06cb6987f0)
Solutions
- Inspect the path: ls -l <project_dir>/mempalace.yaml and confirm its type.
- Remove the offending non-regular file (rm the FIFO) or replace it with a real regular config file.
- Re-run the init command.
Example fix
config_path = Path(project_dir).resolve() / 'mempalace.yaml'
if config_path.exists() and not config_path.is_file():
config_path.unlink() # remove FIFO/named pipe before init
detect_rooms_local(project_dir) Defensive patterns
Strategy: validation
Validate before calling
from pathlib import Path
cfg = Path(project_dir).expanduser().resolve() / 'mempalace.yaml'
if cfg.exists() and not cfg.is_file():
raise SystemExit(f'{cfg} is not a regular file; remove it before init') Type guard
def config_path_writable(project_dir: str) -> bool:
cfg = Path(project_dir).expanduser().resolve() / 'mempalace.yaml'
return not cfg.exists() or cfg.is_file() Prevention
- Check for stray FIFOs/named pipes in project roots before automated init runs.
- Use ls -l or stat to verify config paths are regular files in scripts that prepare projects.
When it happens
Trigger: Running the local setup/init flow when <project_dir>/mempalace.yaml exists as a FIFO, socket, or device file.
Common situations: Test fixtures or pranks creating a named pipe called mempalace.yaml; a symlink loop presenting as non-regular; leftover IPC artifacts in the project root.
Related errors
- query requires exactly one of query_texts or query_embedding
- ChromaBackend has been closed
- pgvector backend requires a local palace path to anchor mism
- qdrant marker is unreadable: {marker_path}
- milvus_consistency_level must be one of: {allowed}
AI-assisted analysis of MemPalace/mempalace@06cb6987f0 (2026-08-15).
Data as JSON: /api/errors/7d0e91cd25c7c6ac.
Report an issue: GitHub.