mimesis-inria / caribou

Multi-physics computation library
GNU Lesser General Public License v3.0
29 stars 17 forks source link

ImportError: libpython3.9.so.1.0: cannot open shared object file: No such file or directory #102

Open coolteemf opened 2 years ago

coolteemf commented 2 years ago

I am using a conda environment in which I built SOFA v21.12 with SofaPython3 (in tree) and caribou v21.12 with SOFA support.

The issue appears when I try to import Caribou at build/v21.12/install/lib/python3/site-packages/Caribou/init.py:1

Full error:

Traceback (most recent call last):
  File "/home/francois/anaconda3/envs/XRAI_3DFlow_pytorch-build/lib/python3.9/site-packages/IPython/core/interactiveshell.py", line 3457, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-2-cb2c892d0da3>", line 1, in <module>
    import Caribou
  File "/snap/pycharm-community/267/plugins/python-ce/helpers/pydev/_pydev_bundle/pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "/home/francois/Projects/caribou/build/v21.12/install/lib/python3/site-packages/Caribou/__init__.py", line 1, in <module>
    from .Caribou  import *
  File "/snap/pycharm-community/267/plugins/python-ce/helpers/pydev/_pydev_bundle/pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
ImportError: libpython3.9.so.1.0: cannot open shared object file: No such file or directory

However, If I first import Sofa and then import Caribou, it works.

jnbrunet commented 2 years ago

Hey François,

Thanks for telling us about this. I will try to have a look at this soon. Good that found a workaround, it should also help us to locate the problem.