build: introduce uv as Python package manager (#16317)

Co-authored-by: QuantumGhost <obelisk.reg+git@gmail.com>
This commit is contained in:
Bowen Liang
2025-04-15 16:16:49 +08:00
committed by GitHub
parent f27a956c71
commit 12de1d175c
23 changed files with 6576 additions and 10991 deletions

View File

@@ -30,14 +30,14 @@ if $api_modified; then
# python style checks rely on `ruff` in path
if ! command -v ruff > /dev/null 2>&1; then
echo "Installing linting tools (Ruff, dotenv-linter ...) ..."
poetry install -C api --only lint
uv sync --project api --only-group lint
fi
# run Ruff linter auto-fixing
ruff check --fix ./api
uv run --project api ruff check --fix ./api
# run Ruff linter checks
ruff check ./api || status=$?
uv run --project api ruff check ./api || status=$?
status=${status:-0}