Getting hnswlib error Index' has no attribute 'file_handle_count'

I am trying to use chromadb which is giving me error:

c:\Users\satya\AppData\Local\Programs\Python\Python39\lib\site-packages\chromadb\config.py in instance(self, type)
hnswlib_count = hnswlib.Index.file_handle_count
hnswlib_count = cast(int, hnswlib_count)
AttributeError: type object 'hnswlib.Index' has no attribute 'file_handle_count'

I am using Python3.9 and versions of hnswlib and chromadb are:

PS C:\Users\satya> pip show hnswlib
Name: hnswlib
Version: 0.7.0
Summary: hnswlib
Home-page:
Author: Yury Malkov and others
Author-email:
License:
Location: c:\users\satya\appdata\local\programs\python\python39\lib\site-packages
Requires: numpy
Required-by:
PS C:\Users\satya> pip show chromadb
Name: chromadb
Version: 0.4.5
Summary: Chroma.
Home-page:
Author:
Author-email: Jeff Huber <[email protected]>, Anton Troynikov <[email protected]>
License:
Location: c:\users\satya\appdata\local\programs\python\python39\lib\site-packages
Requires: chroma-hnswlib, fastapi, importlib-resources, numpy, onnxruntime, overrides, posthog, pulsar-client, pydantic, pypika, requests, tokenizers, tqdm, typing-extensions, uvicorn
Required-by:
1

1 Answer

Using the chromadb==0.4.3 version helped me to resolve the issue with python 3.9

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

You Might Also Like