-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Failed to import C++ bindings for Perspective #937
Comments
@alexeykulakov most likely culprit is that it built against some system libraries instead of what is in the conda env. There is a conda wheel in flight but in the mean time can you |
I've tried another virtual environment |
@alexeykulakov If that doesn't have any errors run cd `python3 -c "import perspective, os.path; print(os.path.dirname(perspective.__file__))"`/table && ldd libpsp.so |
|
This log shows that you’re using a cached wheel, probably from the last time you installed perspective-python. Can you uninstall and reinstall it with -v? That should kick off the build from source process again, which are the logs we need. After install, go to the location where it’s installed and edit ‘libpsp.py’, and add ‘exc_info=True’ to the ‘critical’ log. That should show the actual exception that’s being caught inside that block - posting that here should help narrow the issue down. |
Then got a little bit more info when
|
@alexeykulakov its still using the old wheel, try pip install with |
@timkpaine |
@alexeykulakov its still using your cached version: Try deleteing your pip cache and try again |
|
@alexeykulakov according to that log it got through the build process: |
@timkpaine |
@alexeykulakov can you cd into the perspective/table directory and ldd on libpsp.so and libbinding.so |
@timkpaine
Result:
|
@alexeykulakov that was just a shortcut, but the import logs are making it muddy. |
@timkpaine
|
When pip installs from an sdist (source distribution), it first builds a wheel, then installs it. From your last log, it looks like the necessary shared objects were built ok (i.e. your system is set up fine for building perspective), but then they were not copied into the wheel, so they were not subsequently installed when the wheel was installed. A sideshow here is that shared objects already present in the source distribution were included in the wheel, but they're for the wrong platform (the platform where the sdist was generated, rather than where it's being installed). Probably perspective's setup.py needs adjusting, but I'm not familiar with it enough to say immediately the best way to do that. Since a conda package is in progress (as mentioned above), you could just wait a little, as that will make things much easier. But if you don't want to wait, and since your system is already setup to build successfully, you could could just clone from github and follow the developer installation instructions. Or get the sdist from pypi, then build and install in place by doing something like the following (untested):
The extracted source directory needs to stay around in this case. If instead of step 2 you were to use e.g. |
@ceball |
~soon-ish. conda-forge issue |
Bug Report
I have successfully install perspective-python package with all dependencies (NumPy and PyArrow)
Then I get the warning message when import perspective
So I can't use Table and PerspectiveManager classes.
Command
from perspective import Table, PerspectiveManager
gives the result:Steps to Reproduce:
No errors at this time
Expected Result:
import packages with no errors
Environment:
OS: Ubuntu 19.10
Virtualenv: conda
Python: 3.7.0
The text was updated successfully, but these errors were encountered: