Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[MNT]: Which NumPy version to use for the weekly build? #26730

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

Closed
oscargus opened this issue Sep 9, 2023 · 3 comments
Closed

[MNT]: Which NumPy version to use for the weekly build? #26730

oscargus opened this issue Sep 9, 2023 · 3 comments
Labels
CI: testing CI configuration and testing Maintenance

Comments

@oscargus
Copy link
Member

oscargus commented Sep 9, 2023

Summary

We install both NumPy -pre-version (1.26) and 2.0, but still build MPL with 1.25:

Install Python dependencies:

Collecting numpy
  Obtaining dependency information for numpy from https://files.pythonhosted.org/packages/f9/86/7b6d8e66fa9c2138516b33f6dab9854eae0736c5ab89205398c4622ed37f/numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
  Downloading numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (58 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 58.5/58.5 kB 19.2 MB/s eta 0:00:00
...
Downloading numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (18.2 MB)
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 18.2/18.2 MB 98.3 MB/s eta 0:00:00

Install the nightly dependencies

Collecting numpy
  Downloading https://pypi.anaconda.org/scientific-python-nightly-wheels/simple/numpy/2.0.0.dev0/numpy-2.0.0.dev0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (18.3 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 18.3/18.3 MB 14.8 MB/s eta 0:00:00

Install Matplotlib


Collecting numpy>=1.25
    Obtaining dependency information for numpy>=1.25 from https://files.pythonhosted.org/packages/69/1f/c95b1108a9972a52d7b1b63ed8ca704[66](https://github.com/matplotlib/matplotlib/actions/runs/6129239432/job/16637131200#step:11:67)b59b8c1811bd121f1e6[67](https://github.com/matplotlib/matplotlib/actions/runs/6129239432/job/16637131200#step:11:68)cc45d8/numpy-1.25.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
    Downloading numpy-1.25.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (5.6 kB)
...
  Downloading numpy-1.25.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (18.3 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 18.3/18.3 MB 107.1 MB/s eta 0:00:00

Proposed fix

Wouldn't it make sense to also use one of the upcoming versions during installation?

@oscargus oscargus added Maintenance CI: testing CI configuration and testing labels Sep 9, 2023
@ksunden
Copy link
Member

ksunden commented Sep 11, 2023

This conversation may be reignited at some point, but I think I'm largely okay with using the nightly wheels for now.

There is a bit of a compatibility dance that needs to be done, but I'm not aware of further code changes that I expect to require on our end for np 2.0, and so I think testing against installing main with 2.0 is probably a good thing.

That said, there are ABI changes planned, so code compiled with np<2 may not work with np==2, though the opposite is intended to continue working, to my knowledge.

Official np guidance is to pin to numpy<2.0 for releases (something we have not done for prior releases, but have done for 3.7.3 (#26706) and I am going to do the same for the 3.8 release branch.)

However, mpl is used in numpy's doc building, so they may be forced to do source installs (and potentially git installs) for that to work once the ABI changes hit.

Until quite recently, the nightly wheels, which are built from numpy main, were actually closer to 1.26 than they were to 2.0. So far it is only python deprecations/cleanups that they have merged on main, which we have addressed in our code, so the failures we are seeing are due to third parties (xarray/pandas, mostly)

@oscargus
Copy link
Member Author

My point is rather that we don't build MPL for testing with the nightly wheels, although we install them prior to build MPL, as if the purpose was to actually build it as well. But I may have misunderstood your reply.

@QuLogic
Copy link
Member

QuLogic commented Jul 13, 2024

We always use --no-build-isolation now, so the nightly build will be against the nightly wheels automatically.

@QuLogic QuLogic closed this as completed Jul 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI: testing CI configuration and testing Maintenance
Projects
None yet
Development

No branches or pull requests

3 participants