quaint-telephone-89068
07/01/2026, 7:33 PMresolver = "uv" is set, resolves_to_constraints_file no longer works.
We currently rely on uv pip compile to generate a lockfile and use that as the source of truth for generating the Pants project lockfile. This is because we prefer using uv pip compile to manage package upgrades.
Describe the solution you'd like
It would be great if the resolves_to_constraints_file and resolver = "uv" combination can be supported. We currently have a workaround described below.
Describe alternatives you've considered
We currently use a multi-step workaround:
• uv pip compile to generate a requirements.lock
• generate a temp uv project
• uv add -c requirements.lock to generate a uv.lock
• pants generate-lockfiles --resolve=python-default --python-resolves="{'python-default': 'uv.lock'}" to transform the uv.lock into the Pants project uv lockfile, python-default.lock
It seems that it should therefore work? I may be missing nuances here.
Additional context
With my workaround approach, I had issues with custom indexes and had to specify them twice in pyproject.toml and pants.toml.
pantsbuild/pants