{"record":{"id":"d2cf05b14bd2af6f","repo":"deepset-ai/haystack","slug":"document-store-type-self-document-store-name","errorCode":null,"errorMessage":"Document store {type(self.document_store).__name__} does not provide async support.","messagePattern":"Document store (.+?) does not provide async support\\.","errorType":"exception","errorClass":"TypeError","httpStatus":null,"severity":"error","filePath":"haystack/components/caching/cache_checker.py","lineNumber":114,"sourceCode":"        return {\"hits\": found_documents, \"misses\": misses}\n\n    @component.output_types(hits=list[Document], misses=list)\n    async def run_async(self, items: list[Any]) -> dict[str, Any]:\n        \"\"\"\n        Asynchronously checks if any document associated with the specified cache field is already present in the store.\n\n        :param items:\n            Values to be checked against the cache field.\n        :return:\n            A dictionary with two keys:\n            - `hits` - Documents that matched with at least one of the items.\n            - `misses` - Items that were not present in any documents.\n        \"\"\"\n        found_documents = []\n        misses = []\n\n        if not hasattr(self.document_store, \"filter_documents_async\"):\n            raise TypeError(f\"Document store {type(self.document_store).__name__} does not provide async support.\")\n\n        for item in items:\n            filters = {\"field\": self.cache_field, \"operator\": \"==\", \"value\": item}\n            found = await self.document_store.filter_documents_async(filters=filters)\n            if found:\n                found_documents.extend(found)\n            else:\n                misses.append(item)\n        return {\"hits\": found_documents, \"misses\": misses}\n\n    def close(self) -> None:\n        \"\"\"\n        Release the synchronous resources of the underlying Document Store.\n        \"\"\"\n        if hasattr(self.document_store, \"close\"):\n            self.document_store.close()\n\n    async def close_async(self) -> None:","sourceCodeStart":96,"sourceCodeEnd":132,"githubUrl":"https://github.com/deepset-ai/haystack/blob/e318778c9bf60a1963e3b5f451359655dd696c30/haystack/components/caching/cache_checker.py#L96-L132","documentation":"CacheChecker.run_async raises TypeError when the configured document store lacks a filter_documents_async method. Some stores only implement the synchronous API, so async pipeline execution cannot check the cache.","triggerScenarios":"Running an async pipeline containing CacheChecker with a store such as InMemoryDocumentStore (no async support), i.e. via Pipeline.run_async or an async server.","commonSituations":"Migrating a sync pipeline to async (FastAPI server) without swapping the document store; using a custom or older store version that predates async methods.","solutions":["Use a document store with async support (e.g. one implementing filter_documents_async, like qdrant/pgvector stores).","Keep this component in the synchronous pipeline path and call run() instead of run_async().","Upgrade the store integration package to a version that adds async methods."],"exampleFix":"// before\nchecker = CacheChecker(document_store=InMemoryDocumentStore(), cache_field='text')\nawait pipeline.run_async(...)  # raises\n// after\nchecker = CacheChecker(document_store=QdrantDocumentStore(url=...), cache_field='text')\nawait pipeline.run_async(...)","handlingStrategy":"validation","validationCode":"if not hasattr(store, 'filter_documents_async'):\n    raise TypeError(f'{type(store).__name__} lacks async support; use a sync pipeline')","typeGuard":"def supports_async(store) -> bool:\n    return hasattr(store, 'filter_documents_async')","tryCatchPattern":"try:\n    res = await checker.run_async(items=items)\nexcept TypeError as e:\n    if 'does not provide async support' in str(e):\n        res = checker.run(items=items)\n    else:\n        raise","preventionTips":["Verify store async methods before enabling async pipelines.","Keep async-incompatible stores out of run_async paths.","Pin integration package versions known to support async."],"tags":["async","document-store","cache-checker"],"backgroundTag":"async-unsupported-operation","analyzedSha":"e318778c9bf60a1963e3b5f451359655dd696c30","analyzedAt":"2026-08-30T11:45:20.711Z","schemaVersion":2},"datasetVersion":"2026-08-30T13:17:10.514Z"}