iamdhavalparmar
iamdhavalparmar

Reputation: 1218

not able to install bist in python3

I'm trying to install the blist module in python3 but I'm getting the below error I have tried everything like upgrading the setuptools, pip, wheel, and everything but nothing seems to be working Please help. I'm trying to install elastalert but the blist is the dependency I have to install.

  × python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> [35 lines of output]
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.macosx-10.9-universal2-cpython-39
      creating build/lib.macosx-10.9-universal2-cpython-39/blist
      copying blist/_btuple.py -> build/lib.macosx-10.9-universal2-cpython-39/blist
      copying blist/_sortedlist.py -> build/lib.macosx-10.9-universal2-cpython-39/blist
      copying blist/__init__.py -> build/lib.macosx-10.9-universal2-cpython-39/blist
      copying blist/_sorteddict.py -> build/lib.macosx-10.9-universal2-cpython-39/blist
      running build_ext
      building 'blist._blist' extension
      creating build/temp.macosx-10.9-universal2-cpython-39
      creating build/temp.macosx-10.9-universal2-cpython-39/blist
      clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -iwithsysroot/System/Library/Frameworks/System.framework/PrivateHeaders -iwithsysroot/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.9/Headers -arch arm64 -arch x86_64 -Werror=implicit-function-declaration -Wno-error=unreachable-code -DBLIST_FLOAT_RADIX_SORT=1 -I/Users/dhaval.p/Development/Solo-Alerts/myenv/include -I/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.9/Headers -c blist/_blist.c -o build/temp.macosx-10.9-universal2-cpython-39/blist/_blist.o
      blist/_blist.c:4448:25: warning: code will never be executed [-Wunreachable-code]
                              register PyObject *t;
                              ^~~~~~~~~~~~~~~~~~~~~
      blist/_blist.c:4583:37: error: call to undeclared function '_PyObject_GC_IS_TRACKED'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
                      if (leafs_n > 1 && !_PyObject_GC_IS_TRACKED(leafs[i]))
                                          ^
      blist/_blist.c:5387:31: warning: comparison of integers of different signs: 'Py_ssize_t' (aka 'long') and 'unsigned long' [-Wsign-compare]
                      for (j = 0; j < NUM_PASSES; j++) {
                                  ~ ^ ~~~~~~~~~~
      blist/_blist.c:5393:31: warning: comparison of integers of different signs: 'Py_ssize_t' (aka 'long') and 'unsigned long' [-Wsign-compare]
                      for (j = 0; j < NUM_PASSES; j++) {
                                  ~ ^ ~~~~~~~~~~
      blist/_blist.c:5403:23: warning: comparison of integers of different signs: 'Py_ssize_t' (aka 'long') and 'unsigned long' [-Wsign-compare]
              for (j = 0; j < NUM_PASSES; j++) {
                          ~ ^ ~~~~~~~~~~
      blist/_blist.c:5786:13: error: call to undeclared function '_PyObject_GC_IS_TRACKED'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
              if (_PyObject_GC_IS_TRACKED(self))
                  ^
      4 warnings and 2 errors generated.
      error: command '/usr/bin/clang' failed with exit code 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for blist
  Running setup.py clean for blist
Failed to build blist
ERROR: Could not build wheels for blist, which is required to install pyproject.toml-based projects

Upvotes: -1

Views: 157

Answers (1)

dev_light
dev_light

Reputation: 3899

elastalert supports Python 3.6 while blist supports Python 2.5 - 3.2. You appear to be using Python 3.9, if you're not able to find a similar package that supports recent python versions, you may have to downgrade your python to a version supported by this package.

Upvotes: 0

Related Questions