Add Python 3.14 CI support #161
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: Test & Deploy Numerai Tools | |
| on: | |
| workflow_dispatch: | |
| push: | |
| concurrency: deploy-numerai-tools-${{ github.ref }} | |
| jobs: | |
| test-numerai-tools: | |
| name: Test Numerai Tools (${{ matrix.python-version }}, ${{ matrix.pandas-version }}) | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: [3.11, 3.12, 3.13, 3.14] | |
| pandas-version: | |
| - "pandas>=2.2.2,<2.3" | |
| - "pandas>=2.3,<3.0" | |
| - "pandas>=3.0,<4.0" | |
| exclude: | |
| - python-version: 3.14 | |
| pandas-version: "pandas>=2.2.2,<2.3" | |
| permissions: | |
| id-token: write | |
| contents: read | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 20 | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - uses: snok/install-poetry@v1 | |
| with: | |
| virtualenvs-create: true | |
| virtualenvs-in-project: false | |
| - name: Install dependencies | |
| run: poetry install --with dev | |
| - name: Select pandas version | |
| run: | | |
| poetry run python -m pip install --upgrade "${{ matrix.pandas-version }}" "numpy>=2.0,<2.4" | |
| poetry run python -c "import numpy as np; import pandas as pd; print(f'pandas {pd.__version__}, numpy {np.__version__}')" | |
| - name: Lint | |
| run: poetry run ruff check . | |
| - name: Type Check | |
| run: poetry run mypy . | |
| - name: Test | |
| run: poetry run pytest -W error::FutureWarning | |
| deploy: | |
| name: Deploy Numerai Tools | |
| needs: test-numerai-tools | |
| permissions: | |
| id-token: write | |
| contents: read | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| if: github.ref == 'refs/heads/master' | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - uses: snok/install-poetry@v1 | |
| with: | |
| virtualenvs-create: true | |
| virtualenvs-in-project: false | |
| - name: Install dependencies | |
| run: poetry install | |
| - name: Deploy | |
| id: deploy | |
| run: | | |
| poetry config pypi-token.pypi ${{ secrets.PYPI_API_KEY }} | |
| poetry publish --build |