From 30801c90a4f514f587fe8a309b39c68605978c2e Mon Sep 17 00:00:00 2001 From: Javier Tia Date: Sun, 11 Jan 2026 13:34:07 -0600 Subject: [PATCH 1/2] ci: Streamline documentation workflow and update pre-commit hooks The documentation workflow duplicates logic across multiple separate steps for linting and link checking, making it verbose and harder to maintain when adding or removing markdown files. Additionally, pre-commit hooks are outdated and markdown linting runs only in CI, delaying feedback until after push. Consolidate markdown link checking into a single loop-based step that discovers files dynamically, reducing duplication and simplifying future maintenance. Move markdownlint from CI to pre-commit hooks to catch formatting issues locally before commit. Update pre-commit hook versions to their latest releases for bug fixes and improvements. Signed-off-by: Javier Tia --- .github/workflows/docs.yml | 37 +++++++------------------------------ .pre-commit-config.yaml | 12 +++++++++--- 2 files changed, 16 insertions(+), 33 deletions(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e74aea4..4bd0e2a 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -22,36 +22,13 @@ jobs: with: python-version: "3.11" - - name: Install markdownlint-cli2 - run: npm install -g markdownlint-cli2 - - name: Install markdown-link-check run: npm install -g markdown-link-check - - name: Lint markdown files - run: markdownlint-cli2 "README.md" "CONTRIBUTING.md" "tests/README.md" "docs/**/*.md" - continue-on-error: false - - - name: Check links in README.md - run: markdown-link-check README.md - continue-on-error: false - - - name: Check links in CONTRIBUTING.md - run: markdown-link-check CONTRIBUTING.md - continue-on-error: false - - - name: Check links in tests/README.md - run: markdown-link-check tests/README.md - continue-on-error: false - - - name: Check links in docs/RELEASING.md - run: markdown-link-check docs/RELEASING.md - continue-on-error: false - - - name: Check links in docs/SHELL_COMPLETION.md - run: markdown-link-check docs/SHELL_COMPLETION.md - continue-on-error: false - - - name: Check links in docs/WORKFLOWS.md - run: markdown-link-check docs/WORKFLOWS.md - continue-on-error: false + - name: Check links in markdown files + run: | + for file in README.md CONTRIBUTING.md tests/README.md docs/*.md; do + if [ -f "$file" ]; then + markdown-link-check "$file" + fi + done diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a7ecf13..0a17b63 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,7 +1,7 @@ repos: # File maintenance hooks - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 + rev: v6.0.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -11,7 +11,7 @@ repos: # Ruff linting and formatting - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.8.4 + rev: v0.14.11 hooks: - id: ruff args: [--fix] @@ -19,9 +19,15 @@ repos: - id: ruff-format files: ^src/ + # Markdown linting and formatting + - repo: https://github.com/DavidAnson/markdownlint-cli2 + rev: v0.20.0 + hooks: + - id: markdownlint-cli2 + # Mypy type checking - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.14.1 + rev: v1.19.1 hooks: - id: mypy args: [--strict] From 720de68ca462e702ac0807c6d34e4550fe008fa6 Mon Sep 17 00:00:00 2001 From: Javier Tia Date: Sun, 11 Jan 2026 13:44:21 -0600 Subject: [PATCH 2/2] ci: Remove unused integration test workflow step The integration test step in the GitHub Actions workflow is never executed because the required secrets (GITLAB_TOKEN and GITLAB_REPO) are not configured in the repository. This conditional step adds unnecessary complexity to the workflow definition and creates confusion about whether integration tests are actually part of CI. Remove the integration test step from the workflow. Integration tests can be run locally when needed with the appropriate environment variables, but they are not required for the standard CI pipeline. Signed-off-by: Javier Tia --- .github/workflows/test.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 85cc9e4..ceb2fa1 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -71,14 +71,6 @@ jobs: # The --cov-fail-under=90 in pytest already handles the failure threshold - - name: Run integration tests - if: ${{ secrets.GITLAB_TOKEN != '' && secrets.GITLAB_REPO != '' }} - env: - GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }} - GITLAB_PROJECT_PATH: ${{ secrets.GITLAB_REPO }} - RUN_INTEGRATION_TESTS: "1" - run: uv run pytest tests/integration/ -m integration -v -n auto --no-cov - - name: Upload test results uses: actions/upload-artifact@v4 if: always()