diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml index 45b3571..cb247cf 100644 --- a/.forgejo/workflows/ci.yml +++ b/.forgejo/workflows/ci.yml @@ -1,7 +1,8 @@ name: CI # CI lanes per FabledRulebook/forgejo.md "CI philosophy": -# - backend-lint-and-test: ruff + `pytest -m "not integration"`, no service containers. +# - lint: ruff only, no dep install — fast-fail for the common lint bounce. +# - backend-lint-and-test: `pytest -m "not integration"`, no service containers. # - frontend-build: vitest unit + vite build. # - integration: pgvector + redis service containers; alembic + `pytest -m integration`. @@ -14,6 +15,20 @@ on: # (single-operator Forgejo repo) so push coverage is complete. jobs: + # Fast-fail lint lane. ruff is pre-installed in the ci-python image, so + # this runs with NO dependency install and surfaces the most common bounce + # class (lint: I001 / UP037 / ASYNC109 / W293 …) in seconds — instead of + # after the backend job's ~30-60s wheel install. ruff is static analysis, + # so no DB/secret env is needed. + lint: + runs-on: python-ci + container: + image: git.fabledsword.com/bvandeusen/ci-python:3.14 + steps: + - uses: actions/checkout@v4 + - name: Ruff lint + run: ruff check backend/ tests/ alembic/ + backend-lint-and-test: runs-on: python-ci container: @@ -51,9 +66,8 @@ jobs: pip install -r requirements.txt pytest pytest-asyncio fi - - name: Ruff lint - run: ruff check backend/ tests/ alembic/ - + # Ruff moved to the dedicated fast `lint` job above (fails in seconds, + # no dep install). This job is now unit tests only. - name: Pytest (unit only — integration runs in the integration job) run: pytest tests/ -v -m "not integration"