chroma icon indicating copy to clipboard operation
chroma copied to clipboard

[Bug]: The python process can not exit after creating the ChromaDB client instance

Open ANYMS-A opened this issue 1 year ago • 3 comments

What happened?

Hi, I just found that after creating the ChromaDB client object in python, the process can not exit successfully.

like the code below:

import chromadb

chroma_client = chromadb.HttpClient(host="xxxxxx", port=8000)
print(chroma_client.heartbeat())

after the printing, the process will not exit, is there any way to fix this?

Versions

Windows Python 3.11 chromadb 0.4.24

Relevant log output

No response

ANYMS-A avatar Apr 15 '24 09:04 ANYMS-A

hey @ANYMS-A, we have a PR that addresses this, e.g. closing the http connections and releasing any sockets that might prevent your process from gracefully shutting down - https://github.com/chroma-core/chroma/pull/1792

Look at the PR, and if you want, test it out with your use case to ensure it works. Let me know if you need any more help/instructions.

tazarov avatar Apr 15 '24 09:04 tazarov

hey @ANYMS-A, we have a PR that addresses this, e.g. closing the http connections and releasing any sockets that might prevent your process from gracefully shutting down - #1792

Look at the PR, and if you want, test it out with your use case to ensure it works. Let me know if you need any more help/instructions.

Thanks! That's very helpful. BTW, when will this PR update sync to PyPi?

ANYMS-A avatar Apr 15 '24 11:04 ANYMS-A

Seems a number of community members are having similar issues and we'll try to prioritize this.

tazarov avatar Apr 15 '24 12:04 tazarov