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

pip install tiledb does not install native directory on macOS #105

Closed
kyungminlee opened this issue Jan 21, 2019 · 4 comments
Closed

pip install tiledb does not install native directory on macOS #105

kyungminlee opened this issue Jan 21, 2019 · 4 comments

Comments

@kyungminlee
Copy link

I don't have tiledb installed separately on my macOS. Using miniconda3-latest using pyenv, with python version 3.6, I install tiledb-py through pip install tiledb.

$ python -m tiledb
Traceback (most recent call last):
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/site-packages/tiledb/__init__.py", line 16, in <module>
    ctypes.CDLL(os.path.join(lib_dir, lib_name))
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/ctypes/__init__.py", line 348, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: dlopen(/Users/user/.pyenv/versions/py36/lib/python3.6/site-packages/tiledb/native/libtiledb.dylib, 6): image not found

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/runpy.py", line 183, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/runpy.py", line 142, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/runpy.py", line 109, in _get_module_details
    __import__(pkg_name)
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/site-packages/tiledb/__init__.py", line 19, in <module>
    ctypes.CDLL(lib_name)
  File "/Users/user/.pyenv/versions/py36/lib/python3.6/ctypes/__init__.py", line 348, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: dlopen(libtiledb.dylib, 6): image not found

$ ls /Users/user/.pyenv/versions/py36/lib/python3.6/site-packages/tiledb
__init__.py                     __pycache__                     libtiledb.cpython-36m-darwin.so tests                           version.py

install-tiledb-log.txt

@tdenniston
Copy link
Contributor

It looks like the wheel is not being built by pip (no bdist_wheel was run according to your log). Could you first try explicitly installing the wheel package before TileDB? E.g. pip uninstall tiledb && pip install wheel && pip install tiledb.

If that doesn't work could you please try pip install tiledb --no-cache-dir?

@kyungminlee
Copy link
Author

kyungminlee commented Jan 22, 2019

I have wheel 0.32.3 installed through conda (as you can see in line 38), and I did use pip install tiledb --no-cache-dir. I've tried force installing wheel through pip, but the result is the same.

@ihnorton
Copy link
Member

ihnorton commented Feb 22, 2019

There is a bug in pip which causes --no-cache-dir to skip bdist_wheel, which means that the native library isn't built: pypa/pip#5749

TileDB-Py 0.3.1 was just released, so pip install tiledb should do a fresh build. If you need to avoid the cache, specifying a different cache should work and will force a clean build: pip install --cache-dir=/PATH/TO/mycache tiledb. Or you can remove the global pip cache.

We also have conda packages available on all platforms.

Hopefully the above helps so I will close this -- please comment if this is still and issue and we can reopen.

@ihnorton
Copy link
Member

If you need to avoid the cache, specifying a different cache should work and will force a clean build: pip install --cache-dir=/PATH/TO/mycache tiledb

Hmm, actually this appears to have failed in the same way. So I guess the only option to force a clean build right now is to delete your cache. I just tested pip install tiledb in a clean environment and it worked correctly.

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

No branches or pull requests

3 participants