I found and issue on uv: llvmlite
I’ve found an issue with uv while creating a simple venv. Nothing fancy
with my dependencies. I’ve condensed everything in this issue:
But here is the minimal reproducible example of it:
rm -rf testuv init testcd testuv version# uv venv && uv pip install numpy statsforecastuv add numpy statsforecastFor the time being, I’m using the latest release.
$ uv versionuv 0.5.4 (c62c83c37 2024-11-20)This is what the error looks like:
$ uv init testInitialized project `test` at `/Users/mgreco/github.com/asdf0x2199/blog/test`$ cd test$ uv versionuv 0.5.4 (c62c83c37 2024-11-20)$ uv add numpy statsforecastUsing CPython 3.12.4Creating virtual environment at: .venvResolved 15 packages in 9ms × Failed to download and build `llvmlite==0.36.0` ╰─▶ Build backend failed to determine requirements with `build_wheel()` (exit status: 1)
[stderr] Traceback (most recent call last): File "<string>", line 14, in <module> File "/Users/mgreco/.cache/uv/builds-v0/.tmpgRNnS8/lib/python3.12/site-packages/setuptools/build_meta.py", line 334, in get_requires_for_build_wheel return self._get_build_requires(config_settings, requirements=[]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/mgreco/.cache/uv/builds-v0/.tmpgRNnS8/lib/python3.12/site-packages/setuptools/build_meta.py", line 304, in _get_build_requires self.run_setup() File "/Users/mgreco/.cache/uv/builds-v0/.tmpgRNnS8/lib/python3.12/site-packages/setuptools/build_meta.py", line 522, in run_setup super().run_setup(setup_script=setup_script) File "/Users/mgreco/.cache/uv/builds-v0/.tmpgRNnS8/lib/python3.12/site-packages/setuptools/build_meta.py", line 320, in run_setup exec(code, locals()) File "<string>", line 55, in <module> File "<string>", line 52, in _guard_py_ver RuntimeError: Cannot install on Python version 3.12.4; only versions >=3.6,<3.10 are supported.
help: `llvmlite` (v0.36.0) was included because `test` (v0.1.0) depends on `statsforecast` (v0.7.1) which depends on `numba` (v0.53.1) which depends on `llvmlite`Workaround
If you are lucky, you can try adding dependencies sequentially.
# the order is importantuv add statsforecastuv add numpyIn my case, it solved the problem.
You can also keep using pip for this specific case. The good thing about this
is that despite the limitation, we cannot simply use:
uv venv# inverted order of dependencies (simpler at the end)uv pip install statsforecast numpyI know that this can be time-consuming on a large dependency list, but maybe it is something worth trying.