mdanalysis
mdanalysis copied to clipboard
compile Cython extensions with Cython >= 3.0
Fixes #2988
Changes made in this Pull Request:
- Do not any longer use deprecated NumPy API.
- requires Cython >= 3.0 (tested locally with 3.0a6)
- fixed direct ndarray.base access (using https://github.com/cython/cython/issues/3690#issuecomment-645665793 )
PR Checklist
- [ ] Tests?
- [ ] Docs?
- [ ] CHANGELOG updated?
- [x] Issue raised/referenced?
Hello @orbeckst! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:
- In the file
package/setup.py:
Line 274:80: E501 line too long (124 > 79 characters)
Comment last updated at 2022-04-06 08:11:56 UTC
Note that this will fail until we install Cython 3.0.
Is there something in the travis yml to get cython 3?
We could pip install 'Cython==3.0.0a6' (worked for me) or something like that (and remove cython from the conda/mamba installation).
@orbeckst since cython 3.0 is still in alpha, I'm going to place this as a v2.1.0 milestone, we can shift as necessary.
@orbeckst since cython 3.0 is still in alpha, I'm going to place this as a v2.1.0 milestone, we can shift as necessary.
Moving this to 2.2.0 instead as cython 3 is still in alpha. We'll also need to consider if it should be a breaking change that gets introduced in MDA 3.0.
Moving to 2.3.0 since cython 3.0 is still in alpha
cython 3.0 is staying in alpha for quite a while...
Cython 3.0 is still in alpha, re-targetting 2.4.0.
Cython 3.0 is still in alpha, bumping to 2.5.0.
PR #4129 solved the array problem. The only other thing that this PR does is to get rid of the use of the deprecated NumPy API. However, this requires Cython 3.x so cannot be done in a backward-compatible manner.
I don't think it's worthwhile keeping the PR open for that little patch in setup.py so I am closing it.