scikit-learn-contrib / hdbscan

A high performance implementation of HDBSCAN clustering.
http://hdbscan.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
2.82k stars 507 forks source link

Remove cython from install requires #624

Closed trxcllnt closed 3 months ago

trxcllnt commented 9 months ago

Cython is a build-only dependency, so this PR removes Cython from the install_requires list of the hdbscan package.

setup.py reads requirements.txt to populate its runtime requirements, and requirements.txt incldues cython. So removing it from requirements.txt should be sufficient to fix this.

I can make a separate requirements-build.txt if the maintainers prefer using a requirements file for build dependencies.

jakirkham commented 4 months ago

Should we change this to build with Cython 3+ and NumPy 2+ as well?

https://github.com/scikit-learn-contrib/hdbscan/blob/c201b2e75d42fd0fb7f3aed6b0992afa3c5501c7/pyproject.toml#L1-L7

So...

 [build-system]
 requires = [
   "setuptools",
   "wheel",
-  "cython<4",
+  "cython>=3,<4",
-  "numpy<3"
+  "numpy>=2,<3"
 ]
lmcinnes commented 3 months ago

Thank you!

jakirkham commented 3 months ago

Thank you both! 🙏