Merge pull request #748 from milton-minervino/fix/category-encoders #604
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: | |
| - master | |
| pull_request: | |
| types: [opened, synchronize, reopened] | |
| concurrency: | |
| # Cancel older runs for the same PR/branch when new commits arrive. | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| code_quality: | |
| name: Code Quality | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 20 | |
| steps: | |
| - name: Git checkout | |
| uses: actions/checkout@v6 | |
| - name: Set up Python 3.12 | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.12" | |
| cache: pip | |
| cache-dependency-path: pyproject.toml # it would be better on a lock file | |
| - name: Install dev dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install '.[dev]' | |
| - name: Check linting | |
| run: make lint | |
| - name: Check formatting | |
| run: make format | |
| - name: Check type annotations | |
| run: make typecheck | |
| test: | |
| name: Build & Test | |
| needs: code_quality | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 60 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.11", "3.12", "3.13", "3.14"] | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 # required for setuptools-scm to read git tags | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: pip | |
| cache-dependency-path: pyproject.toml | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install '.[all]' | |
| - name: Build python package | |
| run: | | |
| python -m pip install --upgrade build | |
| python -m build | |
| - name: Test and coverage | |
| run: make coverage |