feat(api): OpenAPI Pydantic codegen + CI drift check (PLAN 3.5) #4
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| permissions: | |
| contents: read | |
| jobs: | |
| validate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: actions/setup-python@v6.2.0 | |
| with: | |
| python-version: "3.12" | |
| cache: pip | |
| cache-dependency-path: apps/api/pyproject.toml | |
| - uses: pnpm/action-setup@v5.0.0 | |
| - uses: actions/setup-node@v6.3.0 | |
| with: | |
| node-version-file: ".nvmrc" | |
| cache: pnpm | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Install API dev dependencies | |
| working-directory: apps/api | |
| run: .venv/bin/python -m pip install -e ".[dev]" | |
| - name: Lint | |
| run: pnpm lint | |
| - name: Test | |
| run: pnpm test | |
| - name: Generate OpenAPI code | |
| run: pnpm openapi:generate | |
| - name: Validate generated OpenAPI code matches the repo | |
| run: pnpm openapi:validate |