This repository was archived by the owner on Jun 15, 2026. It is now read-only.
v1.8.4: --no-cadd flag for licensing exclusion parity #38
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, dev] | |
| tags: ["v*"] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| jobs: | |
| lint-and-test: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 20 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.11", "3.12"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 1 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: pip | |
| - name: Install | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -e ".[dev]" | |
| - name: Generate test fixture | |
| run: python tests/generate_mock_data.py | |
| - name: Ruff check | |
| run: ruff check . | |
| - name: Ruff format check | |
| run: ruff format --check . | |
| - name: Pytest | |
| timeout-minutes: 15 | |
| run: pytest -v --tb=short | |
| version-tag-guard: | |
| if: startsWith(github.ref, 'refs/tags/v') | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Assert tag matches pyproject.toml version | |
| run: | | |
| TAG="${GITHUB_REF#refs/tags/}" | |
| VERSION=$(python3 -c " | |
| import tomllib, pathlib | |
| d = tomllib.loads(pathlib.Path('pyproject.toml').read_text()) | |
| print(d['project']['version']) | |
| ") | |
| EXPECTED="v${VERSION}" | |
| if [ "$TAG" != "$EXPECTED" ]; then | |
| echo "::error::Tag '$TAG' does not match pyproject.toml version '$VERSION' (expected '$EXPECTED')" | |
| exit 1 | |
| fi | |
| echo "Tag '$TAG' matches pyproject.toml version '$VERSION'." |