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

h5py import fails with error on undefined H5Pget_fapl_direct #121

Open
1 task done
bernstei opened this issue Sep 15, 2022 · 1 comment
Open
1 task done

h5py import fails with error on undefined H5Pget_fapl_direct #121

bernstei opened this issue Sep 15, 2022 · 1 comment
Labels

Comments

@bernstei
Copy link

bernstei commented Sep 15, 2022

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

When installing phono3py from conda-forge inside a github CI action, it ends up with conda-forge::h5py-3.7.0-nompi_py39h63b1161_100

This version provides to a broken h5py that cannot be imported. The trivial script python3 -c "import h5py" fails with the error:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/share/miniconda/lib/python3.9/site-packages/h5py/__init__.py", line 33, in <module>
    from . import version
  File "/usr/share/miniconda/lib/python3.9/site-packages/h5py/version.py", line 15, in <module>
    from . import h5 as _h5
  File "h5py/h5.pyx", line 1, in init h5py.h5
ImportError: /usr/share/miniconda/lib/python3.9/site-packages/h5py/defs.cpython-39-x86_64-linux-gnu.so: undefined symbol: H5Pget_fapl_direct

I've tried to use conda to install h5py directly (i.e. not as a dependency of phono3py), but rather than the nompi version that is installed as a phono3py dependency, I end up with h5py pkgs/main/linux-64::h5py-3.7.0-py39h737f45e_0, even though I run conda install -c conda-forge h5py=3.7.0, and I don't know enough about conda to be able to test the package without it being added as a phono3py dependency.

Installed packages

# packages in environment at /usr/share/miniconda:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                  2_kmp_llvm    conda-forge
brotlipy                  0.7.0           py39h27cfd23_1003  
c-ares                    1.18.1               h7f98852_0    conda-forge
ca-certificates           2022.9.14            ha878542_0    conda-forge
cached-property           1.5.2                hd8ed1ab_1    conda-forge
cached_property           1.5.2              pyha770c72_1    conda-forge
certifi                   2022.9.14          pyhd8ed1ab_0    conda-forge
cffi                      1.15.0           py39hd667e15_1  
charset-normalizer        2.0.4              pyhd3eb1b0_0  
colorama                  0.4.4              pyhd3eb1b0_0  
conda                     4.14.0           py39hf3d152e_0    conda-forge
conda-content-trust       0.1.1              pyhd3eb1b0_0  
conda-package-handling    1.8.1            py39h7f8727e_0  
cryptography              36.0.0           py39h9ce1e76_0  
cycler                    0.11.0             pyhd8ed1ab_0    conda-forge
cytoolz                   0.11.0           py39h27cfd23_0  
freetype                  2.12.1               hca18f0e_0    conda-forge
h5py                      3.7.0           nompi_py39h63b1161_100    conda-forge
hdf5                      1.12.1          nompi_h2750804_100    conda-forge
idna                      3.3                pyhd3eb1b0_0  
jpeg                      9e                   h166bdaf_2    conda-forge
kiwisolver                1.4.2            py39h295c915_0  
krb5                      1.19.2               hac12032_0  
lcms2                     2.12                 hddcbb42_0    conda-forge
ld_impl_linux-64          2.35.1               h7274673_9  
libblas                   3.9.0           16_linux64_openblas    conda-forge
libcblas                  3.9.0           16_linux64_openblas    conda-forge
libcurl                   7.84.0               h91b91d3_0  
libedit                   3.1.20210910         h7f8727e_0  
libev                     4.33                 h516909a_1    conda-forge
libffi                    3.3                  he6710b0_2  
libgcc-ng                 12.1.0              h8d9b700_16    conda-forge
libgfortran-ng            12.1.0              h69a702a_16    conda-forge
libgfortran5              12.1.0              hdcd56e2_16    conda-forge
liblapack                 3.9.0           16_linux64_openblas    conda-forge
libnghttp2                1.46.0               hce63b2e_0  
libopenblas               0.3.21          pthreads_h78a6416_3    conda-forge
libpng                    1.6.37               h753d276_4    conda-forge
libssh2                   1.10.0               haa6b8db_3    conda-forge
libstdcxx-ng              9.3.0               hd4cf53a_17  
libtiff                   4.2.0                h85742a9_0  
libwebp-base              1.2.4                h166bdaf_0    conda-forge
libzlib                   1.2.12               h166bdaf_1    conda-forge
llvm-openmp               14.0.4               he0ac6c6_0    conda-forge
lz4-c                     1.9.3                h9c3ff4c_1    conda-forge
matplotlib-base           3.3.4            py39h2fa2bec_0    conda-forge
ncurses                   6.3                  h7f8727e_2  
numpy                     1.20.3           py39hd249d9e_2    conda-forge
olefile                   0.46               pyh9f0ad1d_1    conda-forge
openblas                  0.3.21          pthreads_h[320](https://github.com/libAtoms/workflow/actions/runs/3063889471/jobs/4946460969#step:7:321)a7e8_3    conda-forge
openssl                   1.1.1q               h166bdaf_0    conda-forge
phono3py                  2.3.2            py39h05a0c83_1    conda-forge
phonopy                   2.15.0           py39hd257fcd_0    conda-forge
pillow                    7.2.0            py39h6f3857e_2    conda-forge
pip                       22.1.2           py39h06a4308_0  
pycosat                   0.6.3            py39h27cfd23_0  
pycparser                 2.21               pyhd3eb1b0_0  
pyopenssl                 22.0.0             pyhd3eb1b0_0  
pyparsing                 3.0.9              pyhd8ed1ab_0    conda-forge
pysocks                   1.7.1            py39h06a4308_0  
python                    3.9.12               h12debd9_0  
python-dateutil           2.8.2              pyhd8ed1ab_0    conda-forge
python_abi                3.9                      2_cp39    conda-forge
pyyaml                    6.0              py39hb9d737c_4    conda-forge
readline                  8.1.2                h7f8727e_1  
requests                  2.27.1             pyhd3eb1b0_0  
ruamel_yaml               0.15.100         py39h27cfd23_0  
scipy                     1.5.3            py39hee8e79c_0    conda-forge
setuptools                61.2.0           py39h06a4308_0  
six                       1.16.0             pyhd3eb1b0_1  
spglib                    2.0.1            py39hd257fcd_0    conda-forge
sqlite                    3.38.2               hc218d9a_0  
tk                        8.6.11               h1ccaba5_0  
toolz                     0.11.2             pyhd3eb1b0_0  
tornado                   6.2              py39hb9d737c_0    conda-forge
tqdm                      4.63.0             pyhd3eb1b0_0  
tzdata                    2022a                hda174b7_0  
urllib3                   1.26.8             pyhd3eb1b0_0  
wheel                     0.37.1             pyhd3eb1b0_0  
xz                        5.2.5                h7b6447c_0  
yaml                      0.2.5                h7b6447c_0  
zlib                      1.2.12               h7f8727e_1  
zstd                      1.4.9                ha95c52a_0    conda-forge

Environment info

     active environment : None
       user config file : /home/runner/.condarc
 populated config files : 
          conda version : 4.14.0
    conda-build version : not installed
         python version : 3.9.12.final.0
       virtual packages : __linux=5.15.0=0
                          __glibc=2.31=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /usr/share/miniconda  (writable)
      conda av data dir : /usr/share/miniconda/etc/conda
  conda av metadata url : None
           channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /usr/share/miniconda/pkgs
                          /home/runner/.conda/pkgs
       envs directories : /usr/share/miniconda/envs
                          /home/runner/.conda/envs
               platform : linux-64
             user-agent : conda/4.14.0 requests/2.27.1 CPython/3.9.12 Linux/5.15.0-1019-azure ubuntu/20.04.4 glibc/2.31
                UID:GID : 1001:121
             netrc file : None
           offline mode : False

[edited since conda list output seemed wrong]

@hmaarrfk
Copy link
Contributor

hmaarrfk commented Nov 5, 2024

i have a feeling it is because you are mixing and matching environment with defaults

See
https://conda-forge.org/docs/user/transitioning_from_defaults/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants