chore(deps): align QPK pin to d420441d0e96 #997
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: | |
| test: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 20 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0 | |
| - name: Resolve QuantPlatformKit ref | |
| id: quant-platform-kit-ref | |
| run: | | |
| set -euo pipefail | |
| ref="main" | |
| if [ -n "${GITHUB_HEAD_REF:-}" ]; then | |
| case "${GITHUB_HEAD_REF}" in | |
| dependabot/*) | |
| ;; | |
| *) | |
| if git ls-remote --exit-code --heads https://github.com/QuantStrategyLab/QuantPlatformKit.git "${GITHUB_HEAD_REF}" >/dev/null 2>&1; then | |
| ref="${GITHUB_HEAD_REF}" | |
| fi | |
| ;; | |
| esac | |
| fi | |
| echo "ref=${ref}" >> "$GITHUB_OUTPUT" | |
| - name: Checkout QuantPlatformKit | |
| uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0 | |
| with: | |
| repository: QuantStrategyLab/QuantPlatformKit | |
| ref: ${{ steps.quant-platform-kit-ref.outputs.ref }} | |
| path: external/QuantPlatformKit | |
| - name: Setup Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.11" | |
| - name: Install dependencies | |
| run: | | |
| set -euo pipefail | |
| python -m pip install --upgrade pip | |
| python -m pip install -e . numpy pandas pandas_market_calendars pytz pytest pytest-cov ruff==0.15.22 | |
| python -m pip check | |
| - name: Run Ruff | |
| run: | | |
| set -euo pipefail | |
| ruff check . | |
| - name: Check QPK pin and lock consistency | |
| run: | | |
| set -euo pipefail | |
| python external/QuantPlatformKit/scripts/check_qpk_pin_consistency.py \ | |
| --root . \ | |
| --pin-file external/QuantPlatformKit/QPK_PIN | |
| - name: Run unit tests | |
| run: | | |
| set -euo pipefail | |
| PYTHONPATH=src python -m pytest -q tests --cov --cov-report=term --cov-report=xml |