Skip to content

📝 docs(unxt-hypothesis): update strategies enumeration and explanation #1662

📝 docs(unxt-hypothesis): update strategies enumeration and explanation

📝 docs(unxt-hypothesis): update strategies enumeration and explanation #1662

Workflow file for this run

name: CI
permissions:
contents: read
packages: read
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
# Many color libraries just need this to be set to any value, but at least
# one distinguishes color depth, where "3" -> "256-bit color".
FORCE_COLOR: 3
jobs:
format:
name: Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
- name: Install
run: uv sync --no-default-groups --group nox --group lint --locked
- name: Lint
run: uv run --frozen nox -s lint
# Main package tests
tests-unxt:
name: unxt Python ${{ matrix.python-version }} on ${{ matrix.runs-on }}
runs-on: ${{ matrix.runs-on }}
needs: [format]
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13"]
runs-on: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
with:
python-version: ${{ matrix.python-version }}
- name: Install
run: |
uv sync --no-default-groups --group nox --group test --locked --package unxt
- name: Test package
run: |
uv run --frozen --package unxt nox -s "pytest(package='unxt')" -- --cov --cov-report=xml --cov-report=term --durations=20
- name: Upload coverage report
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
# unxt-api package tests
tests-unxt-api:
name: unxt-api Python ${{ matrix.python-version }} on ${{ matrix.runs-on }}
runs-on: ${{ matrix.runs-on }}
needs: [format]
if: |
github.event_name == 'push' ||
github.event_name == 'workflow_dispatch' ||
contains(github.event.pull_request.labels.*.name, '🧩 unxt-api') ||
startsWith(github.head_ref, 'unxt-api/')
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13"]
runs-on: [ubuntu-latest]
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
with:
python-version: ${{ matrix.python-version }}
- name: Install
run: |
uv sync --no-default-groups --group test --locked --package unxt-api
- name: Test package
run: |
uv run --frozen --package unxt-api pytest packages/unxt-api/tests --cov=packages/unxt-api/src --cov-report=xml --cov-report=term
- name: Upload coverage report
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
# unxt-hypothesis package tests
tests-unxt-hypothesis:
name:
unxt-hypothesis Python ${{ matrix.python-version }} on ${{ matrix.runs-on
}}
runs-on: ${{ matrix.runs-on }}
needs: [format]
if: |
github.event_name == 'push' ||
github.event_name == 'workflow_dispatch' ||
contains(github.event.pull_request.labels.*.name, '🧩 unxt-hypothesis') ||
startsWith(github.head_ref, 'unxt-hypothesis/')
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13"]
runs-on: [ubuntu-latest]
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
with:
python-version: ${{ matrix.python-version }}
- name: Install
run: |
uv sync --no-default-groups --group test --locked --package unxt-hypothesis
- name: Test package
run: |
uv run --frozen --package unxt-hypothesis pytest packages/unxt-hypothesis/tests --cov=packages/unxt-hypothesis/src --cov-report=xml --cov-report=term
- name: Upload coverage report
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
test_oldest:
name: Check Oldest Dependencies
runs-on: ${{ matrix.runs-on }}
needs: [format]
strategy:
fail-fast: false
matrix:
python-version: ["3.11"]
runs-on: [ubuntu-latest]
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
with:
python-version: ${{ matrix.python-version }}
- name: Test package
run: |
uv run --frozen --package unxt --extra all --group test-all --resolution lowest-direct pytest --cov --cov-report=xml --cov-report=term --durations=20 --mpl
- name: Upload coverage report
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
test_interop:
name: Check Interoperability
runs-on: ${{ matrix.runs-on }}
needs: [format]
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13"]
runs-on: [ubuntu-latest]
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
with:
python-version: ${{ matrix.python-version }}
- name: Test package
run: |
uv run --frozen --package unxt --extra all --group test-all pytest --cov --cov-report=xml --cov-report=term --durations=20 --mpl
- name: Upload coverage report
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
benchmark:
name: Run Benchmarks
runs-on: ubuntu-24.04
needs: [format]
if:
github.event_name == 'workflow_dispatch' || (github.event_name ==
'pull_request' && contains(github.event.pull_request.labels.*.name, '⏱️
Run benchmarks')) || (github.event_name == 'push' && github.ref ==
'refs/heads/main')
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5.5.0
- name: Install uv
uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 # v7.1.6
- name: Run benchmarks
uses: CodSpeedHQ/action@972e3437949c89e1357ebd1a2dbc852fcbc57245 # v4.5.1
with:
token: ${{ secrets.CODSPEED_TOKEN }}
mode: instrumentation
run: uv run --group test pytest tests/benchmark --codspeed
status:
name: CI Pass
runs-on: ubuntu-latest
needs: [format, tests-unxt, test_oldest, test_interop]
if: always()
steps:
- name: All required jobs passed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}