Skip to content

build(deps): bump the github-actions group across 1 directory with 8 updates #1125

build(deps): bump the github-actions group across 1 directory with 8 updates

build(deps): bump the github-actions group across 1 directory with 8 updates #1125

Workflow file for this run

name: Code Quality Checks
on:
pull_request:
branches: [main]
types: [opened, synchronize, reopened, ready_for_review]
push:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
python-quality:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Set up Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version-file: ".python-version"
- name: Install uv
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
version: "latest"
enable-cache: true
- name: Install dependencies
run: uv sync --dev
- name: Set PY
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
- uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.cache/pre-commit
key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }}
- name: Run pre-commit python checks (ruff, mypy, etc.)
env:
SKIP: prettier-osprey-ui,eslint-osprey-ui
run: |
uv run pre-commit install --install-hooks
uv run pre-commit run --show-diff-on-failure --color=always --all-files
- name: Check for unused dependencies
run: uv tool run fawltydeps --check-unused --pyenv .venv
ui-quality:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Set up Node.js
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
with:
node-version: "22.22"
- name: Enable Corepack
run: npm install -g corepack@0.33.0 && corepack enable
- name: Install UI dependencies
run: corepack pnpm install --frozen-lockfile
working-directory: osprey_ui
- name: Run prettier check
run: corepack pnpm run format:check
working-directory: osprey_ui
- name: Run eslint check
run: corepack pnpm run lint
working-directory: osprey_ui
- name: Typecheck
run: corepack pnpm run typecheck
working-directory: osprey_ui
- name: Build
run: corepack pnpm run build
working-directory: osprey_ui
rust-quality:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Set up Rust
uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 # master
with:
toolchain: stable
components: rustfmt, clippy
- name: Cache Rust dependencies
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
osprey_coordinator/target/
key: ${{ runner.os }}-cargo-${{ hashFiles('osprey_coordinator/Cargo.lock', 'osprey_coordinator/Cargo.toml') }}
restore-keys: |
${{ runner.os }}-cargo-
- name: Check Rust formatting
run: cargo fmt --check
working-directory: osprey_coordinator
- name: Run Clippy linting
run: cargo clippy -- -D warnings
working-directory: osprey_coordinator
continue-on-error: true
- name: Build Rust project
run: |
sudo apt-get update
sudo apt-get install -y protobuf-compiler
cargo build --verbose
working-directory: osprey_coordinator
- name: Run Rust tests
run: cargo test --verbose
working-directory: osprey_coordinator
continue-on-error: true