fix(deps): update dependency kaleido to v0.2.1.post1 #5084
This file contains 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 - Python Package | |
on: | |
push: | |
branches: [main, feature/*, release/*, hotfix/*] | |
pull_request: | |
branches: [main, develop] | |
repository_dispatch: | |
types: [create-pull-request] | |
jobs: | |
pre-commit: | |
name: Pre-commit | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
- name: Install pre-commit | |
run: | | |
python -m pip install --upgrade pip | |
pip install pre-commit | |
pip freeze --local | |
- name: Cash pre-commit | |
uses: actions/cache@v4 | |
with: | |
path: ~/.cache/pre-commit | |
key: ${{ runner.os }}-pre-commit-${{ hashFiles('**/.pre-commit-config.yaml') }} | |
restore-keys: | | |
${{ runner.os }}-pre-commit- | |
- name: Pre-commit | |
run: | | |
pre-commit run --all-files --color=always | |
build: | |
name: Python ${{ matrix.python-version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} | |
needs: pre-commit | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] | |
os: [ubuntu-latest, windows-latest, macOS-latest] | |
arch: [x64] | |
defaults: | |
run: | |
shell: bash | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: astral-sh/setup-uv@v5 | |
with: | |
enable-cache: true | |
cache-dependency-glob: uv.lock | |
python-version: ${{ matrix.python-version }} | |
- name: Install the project | |
run: uv sync --all-extras --dev | |
- name: Test SpectraFit | |
run: uv run --group dev --all-extras pytest spectrafit/ | |
- name: Codecov | |
uses: codecov/[email protected] | |
with: | |
name: codecov-umbrella | |
flags: unittests | |
verbose: true | |
env_vars: OS,PYTHON | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
minimal-build: | |
name: Build SpectraFit without dev-dependencies | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install uv | |
uses: astral-sh/setup-uv@v5 | |
with: | |
enable-cache: true | |
cache-dependency-glob: uv.lock | |
python-version: "3.10" | |
- name: Install the project | |
run: | | |
uv sync --all-extras | |
uv run pip install -e . | |
install-build: | |
name: Install SpectraFit from wheel | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install uv | |
uses: astral-sh/setup-uv@v5 | |
with: | |
enable-cache: true | |
cache-dependency-glob: uv.lock | |
python-version: "3.10" | |
- name: Setup the project | |
run: | | |
uv sync --all-extras | |
uv build | |
- name: Install the wheel | |
run: | | |
uv pip install dist/*.whl | |
uv run spectrafit -v | |
documentation: | |
name: Build Documentation | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install uv and dependencies with doc-dependencies | |
uses: astral-sh/setup-uv@v5 | |
with: | |
enable-cache: true | |
cache-dependency-glob: uv.lock | |
python-version: "3.10" | |
- name: Install the project | |
run: uv sync --all-extras --group docs | |
- name: Set git config | |
run: | | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Action" | |
- name: Build documentation | |
if: ${{ !contains(github.ref, 'refs/heads/main')}} | |
run: uv run --group docs --all-extras mkdocs build --clean | |
- name: Deploy documentation develops | |
if: contains(github.ref, 'refs/heads/main') | |
run: uv run --group docs --all-extras mike deploy --push --update-aliases develop | |
devcontainer: | |
name: Devcontainer | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build devcontainer | |
uses: devcontainers/[email protected] |