[breaking] migrate from setuptools to uv (#9673)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: hiyouga <16256802+hiyouga@users.noreply.github.com>
This commit is contained in:
Copilot
2025-12-26 22:47:23 +08:00
committed by GitHub
parent 3c17f2722c
commit a1b1931b4a
31 changed files with 178 additions and 250 deletions

View File

@@ -1,24 +1,24 @@
.PHONY: build commit license quality style test
check_dirs := scripts src tests tests_v1 setup.py
check_dirs := scripts src tests tests_v1
build:
pip3 install build && python3 -m build
uv build
commit:
pre-commit install
pre-commit run --all-files
uv run pre-commit install
uv run pre-commit run --all-files
license:
python3 tests/check_license.py $(check_dirs)
uv run python tests/check_license.py $(check_dirs)
quality:
ruff check $(check_dirs)
ruff format --check $(check_dirs)
uv run ruff check $(check_dirs)
uv run ruff format --check $(check_dirs)
style:
ruff check $(check_dirs) --fix
ruff format $(check_dirs)
uv run ruff check $(check_dirs) --fix
uv run ruff format $(check_dirs)
test:
WANDB_DISABLED=true pytest -vv --import-mode=importlib tests/ tests_v1/
WANDB_DISABLED=true uv run pytest -vv --import-mode=importlib tests/ tests_v1/