fix: accept default /tmp/chroma path in ChromaDbConfig validator (#4179)

This commit is contained in:
Br1an
2026-03-23 14:12:49 +05:30
committed by GitHub
parent 7cebaba0a2
commit cc45561abd
2 changed files with 15 additions and 2 deletions
+2 -2
View File
@@ -32,8 +32,8 @@ class ChromaDbConfig(BaseModel):
values.pop("path", None)
return values
# Check if local/server configuration is provided (excluding default tmp path for cloud config)
local_config = bool(path and path != "/tmp/chroma") or bool(host and port)
# Check if local/server configuration is provided
local_config = bool(path) or bool(host and port)
if not cloud_config and not local_config:
raise ValueError("Either ChromaDB Cloud configuration (api_key, tenant) or local configuration (path or host/port) must be provided.")