Skip to content

numba=0.61.2 build 0 still a valid alternative, can result in ImportError: Numba needs NumPy 2.2 or less. Got NumPy 2.3. #159

Description

@tomvothecoder

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

Hello, I think numba=0.61.2 build 0 needs to be marked as unavailable to prevent users from being able to download it. Otherwise, the conda solver can pick it up as a valid alternative which can result in ImportError: Numba needs NumPy 2.2 or less. Got NumPy 2.3. if the latest numpy>2.3 is also picked up.

More Context

In my comment, I noted that the issue appears to stem from build 0 of numba=0.61.2 not enforcing a numpy <2.3 constraint, which led to compatibility problems. A patch was introduced in build 1 of numba=0.61.2, which properly prevents it from being installed with numpy >=2.3.

Now, @jypeter is running into trouble when using conda update --all, which attempts to:

* upgrade `numpy` from 2.2.6 to 2.3.1,

* remove `numba`, `xesmf`, etc.,

* and downgrade `xcdat`, `xskillscore`, and other packages.

This seems to be the conda solver aggressively trying to update all packages, ignoring the compatibility boundaries unless they're explicitly pinned. When he runs conda update --all 'numpy<2.3', everything resolves cleanly.
Source: xCDAT/xcdat#775 (comment)

Someone probably needs to make a PR to conda-forge/admin-requests to fix the version constrain in build 0. Otherwise, that build will still remain a valid alternative. build 1 gets favored over build 0 but that doesn't mean the solver won't fall back on build 0 if it helps solve the whole matrix of dependencies.
Source: xCDAT/xcdat#775 (comment)

Installed packages

numpy>2.3
numba=0.61.2 (build 0)

Environment info

numpy>2.3
numba=0.61.2 (build 0)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions