Skip to content

Differences in uv.lock File Generated by uv sync Across Different Platforms #11312

@junxy

Description

@junxy

Summary

Hi there,
When executing uv sync on different platforms, the uv.lock file is automatically updated. The main observed differences are:

  • On Windows, the entries end with a /.
  • On macOS, the entries do not end with a /.
  • Linux has not been tested.

Additionally, when using uv run python --version, this difference also causes the uv.lock file to be updated.

...
 [[package]]
 name = "aiohappyeyeballs"
 version = "2.4.4"
-source = { registry = "https://pypi.tuna.tsinghua.edu.cn/simple" }
+source = { registry = "https://pypi.tuna.tsinghua.edu.cn/simple/" }
 sdist = { url = "https://pypi.tuna.tsinghua.edu.cn/packages/7f/55/e4373e888fdacb15563ef6fa9fa8c8252476ea071e96fb46defac9f18bf2/aiohappyeyeballs-2.4.4.tar.gz", hash = "sha256:5fdd7d87889c63183afc18ce9271f9b0a7d32c2303e394468dd45d514a757745", size = 21977 }
...

pyproject.toml

#...
[[tool.uv.index]]
url = "https://pypi.tuna.tsinghua.edu.cn/simple"
default = true
#...

Platform

macOS 14 arm64, Windows 11 x86_64

Version

uv 0.5.29 (ca73c47 2025-02-05)

Python version

Python 3.12.3

Metadata

Metadata

Assignees

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