Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PyTables pip install with python 3.11 fails on macOS M1 #102

Open
benrhodes26 opened this issue Sep 9, 2023 · 0 comments
Open

PyTables pip install with python 3.11 fails on macOS M1 #102

benrhodes26 opened this issue Sep 9, 2023 · 0 comments

Comments

@benrhodes26
Copy link

As explained in this stackoverflow post the following error is raised with pip install:

$ python -m pip install tables                                                                                                                                                                                                        ─╯
Collecting tables
  Using cached tables-3.8.0.tar.gz (8.0 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
  error: subprocess-exited-with-error

  × Getting requirements to build wheel did not run successfully.
  │ exit code: 1
  ╰─> [51 lines of output]
      <string>:19: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html

      Error compiling Cython file:
      ------------------------------------------------------------
      ...


      def _dump_h5_backtrace():
          cdef object bt = []

          if H5Ewalk(H5E_DEFAULT, H5E_WALK_DOWNWARD, e_walk_cb, <void*>bt) < 0:
                                                     ^
      ------------------------------------------------------------

      tables/utilsextension.pyx:384:47: Cannot assign type 'herr_t (unsigned int, const H5E_error_t *, void *) except? -1 nogil' to 'H5E_walk_t'
      cpuinfo failed, assuming no CPU features: 'flags'
      * Using Python 3.11.4 (main, Jul 27 2023, 14:26:12) [Clang 14.0.3 (clang-1403.0.22.14.1)]
      * Found cython 3.0.0
      * USE_PKGCONFIG: False
      * Found HDF5 headers at ``/opt/homebrew/opt/hdf5/include``, library at ``/opt/homebrew/opt/hdf5/lib``.
      * Found LZO 2 headers at ``/opt/homebrew/Cellar/lzo/2.10/include``, the library is located in the standard system search dirs.
      * Skipping detection of LZO 1 since LZO 2 has already been found.
      * Found bzip2 headers at ``/opt/homebrew/opt/bzip2/include``, library at ``/opt/homebrew/opt/bzip2/lib``.
      * Found blosc headers at ``/opt/homebrew/opt/c-blosc/include``, library at ``/opt/homebrew/opt/c-blosc/lib``.
      * Found blosc2 headers at ``/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/include``, library at ``/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/lib``.
        * Copying blosc2 runtime library to 'tables' dir because it was not found in standard locations
      Compiling tables/utilsextension.pyx because it changed.
      [1/1] Cythonizing tables/utilsextension.pyx
      Traceback (most recent call last):
        File "/Users/mario.theuermann/.pyenv/versions/i4SEE-sandbox/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/Users/mario.theuermann/.pyenv/versions/i4SEE-sandbox/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/Users/mario.theuermann/.pyenv/versions/i4SEE-sandbox/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
          return hook(config_settings)
                 ^^^^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 341, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=['wheel'])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 323, in _get_build_requires
          self.run_setup()
        File "/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 338, in run_setup
          exec(code, locals())
        File "<string>", line 928, in <module>
        File "<string>", line 923, in get_cython_extfiles
        File "/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/lib/python3.11/site-packages/Cython/Build/Dependencies.py", line 1134, in cythonize
          cythonize_one(*args)
        File "/private/var/folders/h2/tcw923v140sbnqcz0p0xp3y80000gp/T/pip-build-env-n4mpp65u/overlay/lib/python3.11/site-packages/Cython/Build/Dependencies.py", line 1301, in cythonize_one
          raise CompileError(None, pyx_file)
      Cython.Compiler.Errors.CompileError: tables/utilsextension.pyx
      [end of output]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant