Skip to content

Conversation

@scarlehoff
Copy link
Member

@scarlehoff scarlehoff commented Jun 12, 2025

The only changes necessary for numpy 2 were to change from np.<type>_ to np.<type><size>

everything else (meaning, the tests) seem to work ootb. I can evolve fits and benchmarks seem to do ok.

@scarlehoff
Copy link
Member Author

scarlehoff commented Jun 12, 2025

Well, not very useful since banana doesn't work in 3.13 so the actual errors are hidden...
let's see now...

@scarlehoff
Copy link
Member Author

scarlehoff commented Jun 12, 2025

wait what

Why would poetry lock work in my computer but fail to install here?

@felixhekhorn felixhekhorn marked this pull request as draft June 12, 2025 13:13
@felixhekhorn felixhekhorn changed the title [WIP] Python 3.13 support Python 3.13 support Jun 12, 2025
@alecandido
Copy link
Member

Why would poetry lock work in my computer but fail to install here?

The old good question :P

@felixhekhorn
Copy link
Contributor

We should also address #438 here

@felixhekhorn
Copy link
Contributor

Similar story as in NNPDF/banana#78: it wants scipy==1.13.1 (compatible with banana), but only >1.14.1 supports 3.13

@scarlehoff
Copy link
Member Author

scarlehoff commented Jun 13, 2025

I don't know how come locally the code found a path to get an int into the ev_op_max_order argument #441 (comment) I wonder whether there was some cached numba function? I'm quite curious but it doesn't really matter.

What worries / annoys me a bit is that the solution to both this problem and banana's was to run poetry lock without python 3.9 in the toml (so it gets a newer scipy), then running it again with it (then it keeps the newer scipy for 3.13).
Otherwise it tries to use the old scipy for 3.13, which it doesn't find so it tries to build it -> openblas failure.

@felixhekhorn
Copy link
Contributor

What worries / annoys me a bit is that the solution to both this problem and banana's was to run poetry lock without python 3.9 in the toml (so it gets a newer scipy), then running it again with it (then it keeps the newer scipy for 3.13).
Otherwise it tries to use the old scipy for 3.13, which it doesn't find so it tries to build it -> openblas failure.

but this sounds like a poetry bug, no?

@scarlehoff
Copy link
Member Author

I guess? But I don't know whether it is intentional (e.g., versions already in the lockfile take precedence). I don't know enough about poetry to say it is a bug.

@scarlehoff scarlehoff changed the title Python 3.13 support Python 3.13 & numpy 2.0 support Jun 13, 2025
@scarlehoff scarlehoff marked this pull request as ready for review June 13, 2025 09:39
Copy link
Contributor

@felixhekhorn felixhekhorn left a comment

Choose a reason for hiding this comment

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

should we postpone the fix for tar to later?

@scarlehoff
Copy link
Member Author

should we postpone the fix for tar to later?

I think the tar fix is more a curiosity than anything elsee at this point.

Question, is the master branch ready for a 0.15.2 release or should I back port this to the commit from 0.15.1 so that other things merged to master are not included?

(the importance is a bit academic, tensorflow/pytorch only work for python 3.13 in their developement versions so I still need to install those two by hand, might as well do so with eko, but I don't mind backporting this, it should be painless)

Copy link
Contributor

@felixhekhorn felixhekhorn left a comment

Choose a reason for hiding this comment

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

Please add a Changelog entry

@felixhekhorn
Copy link
Contributor

felixhekhorn commented Jun 13, 2025

Question, is the master branch ready for a 0.15.2 release or should I back port this to the commit from 0.15.1 so that other things merged to master are not included?

I think we are ready. The release procedure is now similar to PineAPPL, but still manual and not automated: 0) merge 1) Adjust the Changelog (make a new version there) 2) make that commit the new version

@felixhekhorn felixhekhorn added the dependencies Pull requests that update a dependency file label Jun 13, 2025
@scarlehoff
Copy link
Member Author

scarlehoff commented Jun 13, 2025

I think it is better if you do the changelog.

RE the version file, I've reverted it back. imho there's no perfect solution, but what we do in NNPDF/nnpdf is to create a fake _version.py at build time, which gets ignored and imported by the real version.py https://github.com/NNPDF/nnpdf/blob/bf9a8ec9ab0cc3a4bb356732efc1c9077983b06d/pyproject.toml#L121

thinking about this perhaps it would be better if pre-commit would ensure that it gets back to 0.0.0? I wonder whether there's a ready made hook for that...

@scarlehoff
Copy link
Member Author

scarlehoff commented Jul 8, 2025

Could this be merged before master drifts away?

@felixhekhorn
Copy link
Contributor

I think it is better if you do the changelog.

it wasn't that complicated 5fbe230 😇

Could this be merged before master drifts away?

I'll do as soon as the unit tests have passed

@felixhekhorn felixhekhorn merged commit 94016f0 into master Jul 14, 2025
8 checks passed
@felixhekhorn felixhekhorn deleted the support_3point13 branch July 14, 2025 10:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants