0

I am currently working with Python on an M1 Mac, and I've been facing a persistent issue I hope someone can help with.

I installed the 'tables' library using pipenv (pipenv install tables), which seemed to install successfully without any errors. However, when I attempt to import the library in my Python script with import tables, I encounter an ImportError.

---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
Cell In[1], line 1
----> 1 import tables

File ~/.local/share/virtualenvs/.../lib/python3.10/site-packages/tables/__init__.py:11
      1 """PyTables, hierarchical datasets in Python.
      2 
      3 :URL: http://www.pytables.org/
   (...)
      7 
      8 """
     10 # Necessary imports to get versions stored on the cython extension
---> 11 from .utilsextension import get_hdf5_version as _get_hdf5_version
     14 __version__ = "3.7.0"
     15 """The PyTables version number."""


ImportError: dlopen(/Users/.../.local/share/virtualenvs/.../lib/python3.10/site-packages/tables/utilsextension.cpython-310-darwin.so, 0x0002): symbol not found in flat namespace '_H5Lget_info'

I am running on Python 3.10.9, using PyCharm. I have tried reinstalling, alongside various different installation methods suggested on threads like these:

Installing python tables on mac with m1 chip Could not find HDF5 installation for PyTables on M1 Mac

One thing I did notice that might be relevant was that the install failed when trying to install through the PyCharm terminal with similar error messages to those documented here:

Problems installing pytables on M1 Mac

But when I did the same install by navigating through the normal terminal, the install succeeded.

Any ideas?

0 Answers0