{"record":{"id":"285684d95b345942","repo":"crewAIInc/crewAI","slug":"index-self-index-name-does-not-exist-please-cr","errorCode":null,"errorMessage":"Index {self.index_name} does not exist.  Please create the index before searching.","messagePattern":"Index (.+?) does not exist\\.  Please create the index before searching\\.","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"lib/crewai-tools/src/crewai_tools/tools/couchbase_tool/couchbase_tool.py","lineNumber":116,"sourceCode":"\n        if self.collection_name not in scope_collection_map[self.scope_name]:\n            raise ValueError(\n                f\"Collection {self.collection_name} not found in scope \"\n                f\"{self.scope_name} in Couchbase bucket {self.bucket_name}\"\n            )\n\n        return True\n\n    def _check_index_exists(self) -> bool:\n        \"\"\"Check if the Search index exists in the linked Couchbase cluster\n        Raises a ValueError if the index does not exist.\n        \"\"\"\n        if self.scoped_index:\n            all_indexes = [\n                index.name for index in self._scope.search_indexes().get_all_indexes()\n            ]\n            if self.index_name not in all_indexes:\n                raise ValueError(\n                    f\"Index {self.index_name} does not exist. \"\n                    \" Please create the index before searching.\"\n                )\n        else:\n            if not self.cluster:\n                raise ValueError(\"Cluster instance must be provided\")\n\n            all_indexes = [\n                index.name for index in self.cluster.search_indexes().get_all_indexes()\n            ]\n            if self.index_name not in all_indexes:\n                raise ValueError(\n                    f\"Index {self.index_name} does not exist. \"\n                    \" Please create the index before searching.\"\n                )\n\n        return True\n","sourceCodeStart":98,"sourceCodeEnd":134,"githubUrl":"https://github.com/crewAIInc/crewAI/blob/754d7323beb2fd042e33444a115ea2d5a47193f0/lib/crewai-tools/src/crewai_tools/tools/couchbase_tool/couchbase_tool.py#L98-L134","documentation":"Error \"Index {self.index_name} does not exist.  Please create the index before searching.\" thrown in crewAIInc/crewAI.","triggerScenarios":"Thrown at lib/crewai-tools/src/crewai_tools/tools/couchbase_tool/couchbase_tool.py:116 when the library encounters an invalid state.","commonSituations":"Occurs when the search index does not exist in Couchbase. Create the FTS index before running searches.","solutions":["Create the FTS index in Couchbase before running searches.","Verify the index name matches the configured index_name."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"754d7323beb2fd042e33444a115ea2d5a47193f0","analyzedAt":"2026-08-15T04:06:56.746Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}