Dev 13 #15
17
.github/workflows/ci.yml
vendored
17
.github/workflows/ci.yml
vendored
@@ -28,15 +28,16 @@ jobs:
|
|||||||
pip install -r requirements.txt
|
pip install -r requirements.txt
|
||||||
pip install -r requirements-dev.txt
|
pip install -r requirements-dev.txt
|
||||||
|
|
||||||
- name: Code formatting check (Black)
|
- name: Code style check (isort + Black, one order — no conflict)
|
||||||
run: |
|
run: |
|
||||||
echo "🔍 Checking code formatting with Black..."
|
echo "🔍 Applying isort then black (pyproject.toml: isort profile=black)..."
|
||||||
black --check . || (echo "❌ Code formatting issues found. Run 'black .' to fix." && exit 1)
|
isort .
|
||||||
|
black .
|
||||||
- name: Import sorting check (isort)
|
echo "🔍 Checking that repo is already formatted (no diff after isort+black)..."
|
||||||
run: |
|
git diff --exit-code || (
|
||||||
echo "🔍 Checking import sorting with isort..."
|
echo "❌ Code style drift. Locally run: isort . && black . && git add -A && git commit -m 'style: isort + black'"
|
||||||
isort --check-only . || (echo "❌ Import sorting issues found. Run 'isort .' to fix." && exit 1)
|
exit 1
|
||||||
|
)
|
||||||
|
|
||||||
- name: Linting (flake8) - Critical errors
|
- name: Linting (flake8) - Critical errors
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user