crewAIInc/crewAI · error · ValueError
Index {self.index_name} does not exist. Please create the i
Error message
Index {self.index_name} does not exist. Please create the index before searching. What it means
Error "Index {self.index_name} does not exist. Please create the index before searching." thrown in crewAIInc/crewAI.
Source
Thrown at lib/crewai-tools/src/crewai_tools/tools/couchbase_tool/couchbase_tool.py:116
if self.collection_name not in scope_collection_map[self.scope_name]:
raise ValueError(
f"Collection {self.collection_name} not found in scope "
f"{self.scope_name} in Couchbase bucket {self.bucket_name}"
)
return True
def _check_index_exists(self) -> bool:
"""Check if the Search index exists in the linked Couchbase cluster
Raises a ValueError if the index does not exist.
"""
if self.scoped_index:
all_indexes = [
index.name for index in self._scope.search_indexes().get_all_indexes()
]
if self.index_name not in all_indexes:
raise ValueError(
f"Index {self.index_name} does not exist. "
" Please create the index before searching."
)
else:
if not self.cluster:
raise ValueError("Cluster instance must be provided")
all_indexes = [
index.name for index in self.cluster.search_indexes().get_all_indexes()
]
if self.index_name not in all_indexes:
raise ValueError(
f"Index {self.index_name} does not exist. "
" Please create the index before searching."
)
return True
View on GitHub (pinned to 754d7323be)
Solutions
- Create the FTS index in Couchbase before running searches.
- Verify the index name matches the configured index_name.
When it happens
Trigger: Thrown at lib/crewai-tools/src/crewai_tools/tools/couchbase_tool/couchbase_tool.py:116 when the library encounters an invalid state.
Common situations: Occurs when the search index does not exist in Couchbase. Create the FTS index before running searches.
AI-assisted analysis of crewAIInc/crewAI@754d7323be (2026-08-15).
Data as JSON: /api/errors/285684d95b345942.
Report an issue: GitHub.