---
id: 20261102-T0-05
title: "Python 3.15依赖报错？Simon Willison的解法：删掉uv.lock"
title_en: "Simon Willison's Fix for Python 3.15 Dependency Errors: Delete uv.lock"
url: https://ai.daily.yangsir.net/daily/20261102-T0-05
issue_date: 2026-11-02
publish_date: 2026-11-01T23:24:22.000Z
category: insight
source_name: "Simon Willison"
source_url: https://simonwillison.net/2026/Nov/1/delete-uv-lock-first/
---

# Python 3.15依赖报错？Simon Willison的解法：删掉uv.lock

开发者Simon Willison称，切换到Python 3.15后偶尔遇到令人困惑的依赖错误，他的应对办法是删掉uv.lock文件。他指出自己的多数项目是库，本就不该包含uv.lock，因为库锁定依赖版本会对下游使用者造成困扰。这条经验针对使用uv管理依赖并升级到Python 3.15的开发者，遇到难以定位的依赖冲突时，先删除锁文件重新解析往往比逐条排查更快。

## English Version

**Simon Willison's Fix for Python 3.15 Dependency Errors: Delete uv.lock**

Developer Simon Willison reports occasional confusing Python dependency errors after switching to Python 3.15, and his rule is simple: when in doubt, delete the uv.lock file. He notes most of his projects are libraries, which shouldn't ship a lockfile anyway since locking versions is rude to downstream consumers. The takeaway is aimed at developers using uv on Python 3.15: when dependency conflicts are hard to trace, deleting the lockfile and re-resolving is often faster than debugging line by line.

---

**来源**：[Simon Willison](https://simonwillison.net/2026/Nov/1/delete-uv-lock-first/)

**详情页**：https://ai.daily.yangsir.net/daily/20261102-T0-05

---

*智语观潮 · Daily — https://ai.daily.yangsir.net/llms.txt*