uv icon indicating copy to clipboard operation
uv copied to clipboard

"uv sync -U" update also pyproject.toml package version

Open muk-as opened this issue 1 year ago • 1 comments

in pyproject.toml was fastapi>=0.113 uv sync -U will update fastapi to 0.114 in .venv, uv.lock but in pyproject.toml still fastapi>=0.113 all ok, but i think will be better change on fastapi>=0.114

muk-as avatar Sep 06 '24 22:09 muk-as

This is the intended behavior — upgrading changes the locked version within the constraints you provide in your pyproject.toml: https://docs.astral.sh/uv/concepts/projects/#upgrading-locked-package-versions

It'd be weird for us to change the specification of the dependency itself on sync — it'd be best implemented as some other dedicated command. I think there are some other issues tracking support for that but having a hard time tracking them down right now.

zanieb avatar Sep 07 '24 15:09 zanieb