-
Notifications
You must be signed in to change notification settings - Fork 727
Description
Expected behavior
pip install build/compiles cleanly
Actual behavior
See https://discord.com/channels/807348386012987462/808088023957897258/1381767573611483176 by @ljwoods2
Curious if I'm missing something, is anyone else getting a Numpy compatibility issue when trying to build MDA from source with pip? Looks like transformations.c relies on the old numpy API (NPY_IN_ARRAY, etc), and I can't build wheel sucessfully and clear errors like this (long list of them from MDAnalysis/lib/src/transformations/transformations.c) unless I change numpy to an earlier version (<1.24) in the build-system "requires" list:
MDAnalysis/lib/src/transformations/transformations.c:794:57: error: ‘NPY_ALIGNED’ undeclared (first use in this function); did you mean ‘Py_ALIGNED’?
*address = PyArray_FROM_OTF(object, NPY_DOUBLE, NPY_ALIGNED);
Plus, above should throw a deprecation warning / error instead of just failing, right? I see @orbeckst 's issue (#2988) about suppressing the deprecated warnings, but looks like it hasn't been fixed yet, so I should still see the warning?
Apologies if this is something obvious, but I figured Numpy >2.0 is supposed to be able to handle the old API usage? If this is not just me being dumb I will raise an issue
Code to reproduce the behavior
All I did was:
git clone [email protected]:MDAnalysis/mdanalysis.git
git checkout develop
conda create -n broken python=3.11 pip
conda activate broken
cd mdanalysis/package
pip install .
Current version of MDAnalysis
- Which version are you using? (run
python -c "import MDAnalysis as mda; print(mda.__version__)"
) - Which version of Python (
python -V
)? - Which operating system?