Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ def main():

install_requires = [
'numpy<2.0; python_version<"3.9"',
'numpy>=2; python_version>="3.9"',
'numpy>=2.0.2; python_version>="3.9" and python_version<"3.13"',
'numpy>=2.1.3; python_version>="3.13" and python_version<"3.14"',
'numpy>=2.3.0; python_version>="3.14"',

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the overly restrictive patch version pin ?

Suggested change
'numpy>=2.0.2; python_version>="3.9" and python_version<"3.13"',
'numpy>=2.1.3; python_version>="3.13" and python_version<"3.14"',
'numpy>=2.3.0; python_version>="3.14"',
'numpy>=2.0; python_version>="3.9" and python_version<"3.13"',
'numpy>=2.1; python_version>="3.13" and python_version<"3.14"',
'numpy>=2.3; python_version>="3.14"',

python_version< should also be redundant, given that on higher python versions, the numpy version is already restricted to a higher bound.

Unlocking the pin was also handled in 7bd1825

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, thanks — the patch-level pins weren't deliberate, just over-specific. Applied your suggestion.

One small deviation: I kept a patch-level floor for 3.14. Checking PyPI, 2.3.0 and 2.3.1 ship no cp314 wheels — 2.3.2 is the first release that does — so >=2.3.2 is the accurate floor there. >=2.1 for 3.13 matches the same way, since 2.1.0 is the first with cp313 wheels.

Happy to drop the python_version< upper bounds as you suggested if you'd prefer — they are redundant, since the highest applicable floor wins. I left them only because your snippet kept them; say the word and I'll simplify.

]

python_version = cmaker.CMaker.get_python_version()
Expand Down
Loading