Skip to content

Commit da4060a

Browse files
authored
feat: add macOS support to uv lockfile and torch sources (#61)
The lockfile was restricted to `sys_platform == 'linux'`, so `uv run pixelshot` failed on macOS. Add darwin to the environments list, gate the CUDA torch index and nvidia-cudnn override behind a Linux marker so macOS resolves CPU-only wheels from PyPI instead.
1 parent 1119c84 commit da4060a

2 files changed

Lines changed: 548 additions & 236 deletions

File tree

pyproject.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,12 @@ include = [
9696
]
9797

9898
[tool.uv]
99-
override-dependencies = ["nvidia-cudnn-cu12==9.20.0.48"]
100-
environments = ["sys_platform == 'linux'"]
99+
override-dependencies = ["nvidia-cudnn-cu12==9.20.0.48; sys_platform == 'linux'"]
100+
environments = ["sys_platform == 'linux'", "sys_platform == 'darwin'"]
101101

102102
[tool.uv.sources]
103-
torch = [{ index = "pytorch-cu129" }]
104-
torchvision = [{ index = "pytorch-cu129" }]
103+
torch = [{ index = "pytorch-cu129", marker = "sys_platform == 'linux'" }]
104+
torchvision = [{ index = "pytorch-cu129", marker = "sys_platform == 'linux'" }]
105105

106106
[[tool.uv.index]]
107107
name = "pytorch-cu129"

0 commit comments

Comments
 (0)