RyanCodrai/turbovec · error · ValueError
namespace must not contain ':' (a Windows drive-relative nam
Error message
namespace must not contain ':' (a Windows drive-relative name like 'C:foo' escapes persist_dir); got {namespace!r}. It names a store within persist_dir, not a path. What it means
Raised in _validate_namespace when the namespace contains ':'. On Windows a colon forms a drive-relative name like 'C:foo' that escapes persist_dir without any path separator, bypassing the separator check; such namespaces are rejected rather than silently rewritten.
Source
Thrown at turbovec-python/python/turbovec/llama_index.py:176
(alphanumerics, dash, underscore, dots, and other non-separator
characters); dotted namespaces such as ``v1.2`` map to distinct
file pairs and coexist in one ``persist_dir``.
This is a deliberate divergence from ``SimpleVectorStore``, which does
not sanitize its namespace, in the safer direction.
"""
if namespace == "" or namespace == ".":
raise ValueError(
f"namespace must be a non-empty name, got {namespace!r}"
)
if "/" in namespace or "\\" in namespace or os.sep in namespace or ".." in namespace:
raise ValueError(
"namespace must not contain path separators ('/' or '\\\\') or "
f"'..'; got {namespace!r}. It names a store within persist_dir, "
"not a path."
)
if ":" in namespace:
raise ValueError(
"namespace must not contain ':' (a Windows drive-relative name "
f"like 'C:foo' escapes persist_dir); got {namespace!r}. It "
"names a store within persist_dir, not a path."
)
return namespace
def _split_persist_base(persist_path: str | Path) -> Path:
"""Derive the on-disk base from ``persist_path``: the binary index is
written to ``{base}.tvim`` and the node side-car to
``{base}.nodes.json`` (extensions *appended* — see ``_with_ext``).
Only a trailing ``.json`` — the conventional extension the framework
hands us via ``{namespace}__vector_store.json`` — is stripped; every
other character of the name is kept verbatim, including dots from a
dotted namespace. ``v1.2__vector_store.json`` and
``v1.3__vector_store.json`` therefore map to distinct file pairs.
(The previous ``with_suffix``-based implementation re-split the stemView on GitHub (pinned to ccab9f325e)
Solutions
- Remove ':' from the namespace (e.g. 'C:foo' -> 'C_foo').
- Sanitize user-supplied namespace strings before constructing the store.
- Catch the ValueError in tooling as part of the namespace path-escape defenses.
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at turbovec-python/python/turbovec/llama_index.py:176 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of RyanCodrai/turbovec@ccab9f325e (2026-09-06).
Data as JSON: /api/errors/43da975320392ef7.
Report an issue: GitHub.