Skip to content
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

Potential need to update numpy version to 2.0 #1030

Open
paulf81 opened this issue Nov 15, 2024 · 1 comment
Open

Potential need to update numpy version to 2.0 #1030

paulf81 opened this issue Nov 15, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@paulf81
Copy link
Collaborator

paulf81 commented Nov 15, 2024

Potential need to update numpy version

I've been re-installing FLORIS/python following an OS update and received this error on install:

error: Failed to prepare distributions
  Caused by: Failed to download and build `numpy==1.24.4`
  Caused by: Build backend failed to determine requirements with `build_wheel()` (exit status: 1)

[stderr]
Traceback (most recent call last):
  File "<string>", line 8, in <module>
    from setuptools.build_meta import __legacy__ as backend
  File "/Users/pfleming/.cache/uv/builds-v0/.tmpbOAuSo/lib/python3.13/site-packages/setuptools/__init__.py", line 10, in <module>
    import distutils.core
ModuleNotFoundError: No module named 'distutils'
  Caused by: distutils was removed from the standard library in Python 3.12. Consider adding a constraint (like `numpy >1.24.4`) to avoid building a version of numpy that depends on distutils.

We use currently numpy~=1.20 which means we can jump up to v2. I think for now I can back myself to python 3.11 to get around this issue but wanted to flag the potential.

Proposed solution

Update numpy requirement to 2.0 and make any required changes

@paulf81 paulf81 added the bug Something isn't working label Nov 15, 2024
@paulf81 paulf81 self-assigned this Nov 15, 2024
@thebaptiste
Copy link

thebaptiste commented Dec 12, 2024

Yes, a new release compatible with numpy 2 would be appreciated.

May be you don't need to have a requirement such as numpy~=2.0 but rather such as numpy>=1.20 ?
May be I'm wrong but I'm not found of this kind of dependency requirements (~=) preventing any testing with new releases of dependencies (which might possibly succeed)

By the way I can install floris and numpy 2.0 (even 2.1 or 2.2) together (pip install floris "numpy>=2")... but it installs floris 3.5 which did'nt have numpy~=1.20 in its requirements and I'm sure it won't work better with numpy 2 than floris 4.2.1 !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants