Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 0 additions & 23 deletions .github/workflows/rhiza_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,29 +90,6 @@ jobs:
path: _tests/coverage.xml
if-no-files-found: ignore


docs-coverage:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6.0.2

- name: Install uv
uses: astral-sh/setup-uv@v7.6.0
with:
version: "0.10.12"

- name: Configure git auth for private packages
uses: ./.github/actions/configure-git-auth
with:
token: ${{ secrets.GH_PAT }}

- name: Check docs coverage
env:
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
run: |
make docs-coverage

coverage-badge:
needs: test
runs-on: ubuntu-latest
Expand Down
55 changes: 55 additions & 0 deletions .github/workflows/rhiza_docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# This file is part of the jebel-quant/rhiza repository
# (https://github.com/jebel-quant/rhiza).
#
# Workflow: Docs Coverage
#
# Purpose: This workflow enforces 100% docstring coverage on all public methods
# using interrogate. Without enforcement, new methods added without
# docstrings silently produce blank pages in the MkDocs API reference.
# On release tags (v*), it also deploys versioned documentation to
# GitHub Pages using mike.
#
# Trigger: This workflow runs on every push and on pull requests to main/master
# branches (including from forks), and on release tags (v*).

name: "(RHIZA) DOCS"

on:
push:
branches: [ main, master ]
tags:
- "v*"
pull_request:
branches: [ main, master ]

jobs:
docs-coverage:
name: Check docstring coverage with interrogate
runs-on: ubuntu-latest

# Permissions: Only read access to repository contents is needed
permissions:
contents: read

steps:
- uses: actions/checkout@v6.0.2

- name: Install uv
uses: astral-sh/setup-uv@v7.6.0
with:
version: "0.10.12"

- name: Configure git auth for private packages
uses: ./.github/actions/configure-git-auth
with:
token: ${{ secrets.GH_PAT }}

- name: Run docs-coverage
run: make docs-coverage
# NOTE: make docs-coverage uses interrogate to enforce 100% docstring
# coverage on all public methods. Configuration is read from
# [tool.interrogate] in pyproject.toml.

VERSION="${GITHUB_REF_NAME#v}"
uv run mike deploy --push --update-aliases "$VERSION" latest
uv run mike set-default --push latest
1 change: 1 addition & 0 deletions .rhiza/docs/CONFIG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ The repository uses several automated workflows (located in `.github/workflows/`
- **Requires:** `PAT_TOKEN` secret with `workflow` scope when modifying workflow files
- See [TOKEN_SETUP.md](TOKEN_SETUP.md) for configuration
- **CI** (`rhiza_ci.yml`) - Continuous integration tests
- **Docs** (`rhiza_docs.yml`) - Documentation coverage (interrogate) and versioned deployment (mike)
- **Pre-commit** (`rhiza_pre-commit.yml`) - Code quality checks
- **Book** (`rhiza_book.yml`) - Documentation deployment
- **Release** (`rhiza_release.yml`) - Package publishing
Expand Down
1 change: 1 addition & 0 deletions docs/ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,7 @@ Documentation files use SCREAMING_SNAKE_CASE:
GitHub Actions workflows use the pattern `rhiza_<feature>.yml`:

- `rhiza_ci.yml` - Continuous integration
- `rhiza_docs.yml` - Documentation coverage and versioned deployment
- `rhiza_release.yml` - Release automation
- `rhiza_security.yml` - Security scanning
- `rhiza_sync.yml` - Template synchronization
Expand Down
Loading