-
-
Notifications
You must be signed in to change notification settings - Fork 41
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
Boost.Python and segmentation faults with numpy 1.21 #127
Comments
A fix in numpy is described in this issue: boostorg/python#376 and I will open a numpy PR. The problem involved dereferencing a null pointer when checking convertibility of types (like boost_python ones) that haven't implemented the new numpy casting implementation. |
So |
That could make sense. Though we will want to include that constraint in the package here as well cc @conda-forge/core (in cases others have thoughts here) |
Oops, |
Are people still running into this issue? |
The problem is invisible with numpy >= 1.21.5 due to np PR 20616. Nominally that is a temporary fix that may be removed at some point. At the time I had made some type of reproducer in a container that could demonstrate this problem; I'm happy to try to pull it back together if you are interested in revisiting this. |
Fair. Well I think the answer then is to fix in Boost.Python (as Sebastian put it in the issue). We can of course backport a patch once that makes its way upstream, but that would be the best use of time (if you have any and no worries if not) |
We do nightly builds and tests of our conda package so we'll know if the temporary fix is no longer available pretty quickly. The Boost.Python and NumPy developers are aware of the issue, so I guess we can close this issue for now. Or should we keep it open for tracking? |
Closing this issue as obsolete. If there are still problems with numpy + |
Issue:
Due to NEP 42 being accepted as being the new datatype system for numpy 1.21, C++ extensions wrapped with Boost.Python will get segmentation faults. There is an issue created upstream by @jawsc-alan (boostorg/python#376). @dwpaley did the work to find the commit where the behavior changed. It is also possible to reproduce the behavior in numpy 1.20 by building with the
NPY_USE_NEW_CASTINGIMPL
environment variable.Most likely, Boost.Python will need to be updated to handle the new datatype system.
PR to enable testing NEP 42 (numpy/numpy#17401)
PR to set NEP 42 as the default (numpy/numpy#18676)
Environment (
conda list
):Details about
conda
and system (conda info
):The text was updated successfully, but these errors were encountered: