-
Notifications
You must be signed in to change notification settings - Fork 805
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
uv sync
fails in xarray, while pip install
succeeds
#7881
Comments
Without looking, my guess is that it's something like this, where we end up solving in a different order than pip and thus end up picking a newer version of something that leads to us using an old llvmlite. |
If you |
If you run
|
Thanks for such a kindly written issue btw. |
I would need to look at the |
Thank you very much for the fast response! You're going to put LLMs out of a job already. Forcing the latest version of diff --git a/pyproject.toml b/pyproject.toml
index 4f33eff8..7d18a7d3 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -23,6 +23,7 @@ requires-python = ">=3.10"
dependencies = [
"numpy>=1.24",
+ "numba==0.60.0",
"packaging>=23.1",
"pandas>=2.1",
] (Forcing the latest version of Any idea why it's selecting numba 0.53.1? That version's setup.py file seems to specify a much earlier numpy version as a constraint, though possibly in a format that can't be read? (Could look more unless this is obvious to you) The case of "no version of A supports the latest version of B, so install the version of B which a version of A supports" seems like it should be a common path; I'd have expected to find that some dependency has misspecified a constraint... |
I think it's because newer versions of Numba include:
So if we choose the latest NumPy, we end up having to backtrack to versions of Numba that don't include that upper-bound. |
Ah yes, OK:
and then no upper bound at:
Let me try and fix by giving constraints in xarray for |
OK great, this works! diff --git a/pyproject.toml b/pyproject.toml
index 4f33eff8..c6dd762d 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -28,7 +28,7 @@ dependencies = [
]
[project.optional-dependencies]
-accel = ["scipy", "bottleneck", "numbagg", "flox", "opt_einsum"]
+accel = ["scipy", "bottleneck", "numbagg", "numba>=0.54", "flox", "opt_einsum"]
complete = ["xarray[accel,etc,io,parallel,viz]"]
dev = [
"hypothesis", Thank you very much! Will push this change.
|
So we're compatible with astral-sh/uv#7881. Notes inline
So we're compatible with astral-sh/uv#7881. Notes inline
Yeah we plan to improve these heuristics in the long-term but it's going to be quite the challenge |
Thanks for making
uv
! I'm trying it out for xarray. We've had great success withruff
.Currently this doesn't succeed:
It's surprising that it's attempting to select an old version of
llvmlite
. When I runpip install .[complete]
in the venv, I get a successful install, with version0.43.0
ofllvmlite
.Happy to debug a bit. I had a browse through https://docs.astral.sh/uv/pip/compatibility/. Is there anything I should look at / any way of understanding why
uv
doesn't succeed there? Is a dependency giving bad information thatpip
is ignoring?Rather than me bugging you, one great model would be to print why it's choosing that package, and someone like me could open an issue on the offending dependency (but maybe not easy...)
Thanks!
The text was updated successfully, but these errors were encountered: