-
-
Save ashmalvayani/ab3f4a8469fe3a2e9904c3a2674ea947 to your computer and use it in GitHub Desktop.
Chromadb specifically works on python version 3.10.10. Saw on other github issues that it does not work with other python versions. | |
to install chromadb, write the following command: | |
pip install chromadb | |
if you are getting the following build error: | |
Building wheels for collected packages: chroma-hnswlib | |
Building wheel for chroma-hnswlib (pyproject.toml) ... error | |
error: subprocess-exited-with-error | |
× Building wheel for chroma-hnswlib (pyproject.toml) did not run successfully. | |
│ exit code: 1 | |
╰─> [5 lines of output] | |
running bdist_wheel | |
running build | |
running build_ext | |
building 'hnswlib' extension | |
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/ | |
[end of output] | |
note: This error originates from a subprocess, and is likely not a problem with pip. | |
ERROR: Failed building wheel for chroma-hnswlib | |
Failed to build chroma-hnswlib | |
ERROR: Could not build wheels for chroma-hnswlib, which is required to install pyproject.toml-based projects | |
---------------- | |
Then do the following: | |
1. install VS C++ build tools by following this website: | |
https://learn.microsoft.com/en-us/answers/questions/136595/error-microsoft-visual-c-14-0-or-greater-is-requir | |
2. Once the installation is complete, close your terminal where you were installing the module and open a new terminal and run the command again. | |
3. It will work. |
SOLUTION#02: If you are running this command on linux machine and your error only shows: "Gcc error: gcc: error trying to exec 'cc1': execvp: No such file or directory"
OR
RuntimeError: Unsupported compiler -- at least C++11 support is needed!
Then you need to run the following command on your linux machine and that should work: sudo apt-get update sudo apt-get install --reinstall build-essential
on top of it add
sudo apt install python3-dev
I had the same problem in my vscode in windows. I tried all fixes i found in web sites, but still i hadd issue.
Finally I solved it with a change from python 3.12 to python 3.11 in my .venv (by changing .venv/pyenv.cfg file) and then I could pip install without any issues!
then I switched back to python 3.12 again and that worked fine.
Hi All, Faced the same issue about
ERROR: Failed building wheel for chroma-hnswlib
Then as per help from StackOverflow installed the VS and selected Indivdual Components. However, it did not worked. Then I added below package as shown in image and it works fine.
Note: Using Windows 10 x64-bit
It's also help me to resolve my issue thanks!
Hi All, Faced the same issue about
ERROR: Failed building wheel for chroma-hnswlib
Then as per help from StackOverflow installed the VS and selected Indivdual Components. However, it did not worked. Then I added below package as shown in image and it works fine.
Note: Using Windows 10 x64-bit
Worked for Windows 11 as well
Hi All, Faced the same issue about
ERROR: Failed building wheel for chroma-hnswlib
Then as per help from StackOverflow installed the VS and selected Indivdual Components. However, it did not worked. Then I added below package as shown in image and it works fine.
Note: Using Windows 10 x64-bit
This work, youre a god man
Hi All, Faced the same issue about
ERROR: Failed building wheel for chroma-hnswlib
Then as per help from StackOverflow installed the VS and selected Indivdual Components.
However, it did not worked. Then I added below package as shown in image and it works fine.
Note: Using Windows 10 x64-bit