Update CI workflow to use uv for testing and packaging; enhance development documentation on dependency management
Some checks failed
构建扩展 / build (push) Failing after 5m10s
构建并部署文档 / deploy (push) Failing after 2m54s

This commit is contained in:
2026-08-19 20:24:35 +08:00
parent 8c037fc8a9
commit 9bb603b532
3 changed files with 7 additions and 9 deletions

View File

@@ -15,20 +15,16 @@ jobs:
- name: 检出代码 - name: 检出代码
uses: actions/checkout@v6 uses: actions/checkout@v6
- name: 配置 Python - name: 配置 uv
uses: actions/setup-python@v6 uses: astral-sh/setup-uv@v7
with: with:
python-version: "3.12" python-version: "3.12"
cache: pip
- name: 安装测试依赖
run: python -m pip install numpy pytest
- name: 运行测试 - name: 运行测试
run: python -m pytest run: uv run --frozen pytest
- name: 构建扩展 - name: 构建扩展
run: python pack.py run: uv run --frozen python pack.py
- name: 上传扩展包 - name: 上传扩展包
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7

View File

@@ -108,4 +108,4 @@ Session 逐帧推理,显存峰值不随视频帧数平方增长。Debug 只保
Blender 侧只负责界面、任务提交与结果导入,AI 与文件输出由独立 Job Server 执行。详细功能见 Blender 侧只负责界面、任务提交与结果导入,AI 与文件输出由独立 Job Server 执行。详细功能见
[文档索引](docs/index.md),模块边界、调用流程、项目结构与开发命令见 [文档索引](docs/index.md),模块边界、调用流程、项目结构与开发命令见
[程序设计、开发与许可证](docs/development.md)。 [程序设计、开发与许可证](docs/development.md)。开发与 CI 使用 `uv.lock` 中锁定的依赖运行测试和打包。

View File

@@ -109,6 +109,8 @@ uv run pytest tests/test_addon.py tests/test_manifest.py tests/test_pack.py -v
uv run python pack.py uv run python pack.py
``` ```
`.github/workflows/build.yml` 使用 Python 3.12 与 `uv.lock` 中锁定的开发依赖运行完整测试和打包;新增测试依赖时应在 `pyproject.toml` 的 `dev` 依赖组中声明并更新锁文件,不要在 Workflow 中另行维护 `pip install` 清单。
本地预览用户文档: 本地预览用户文档:
```bash ```bash