From ca35eb35a61ff3914da17241c6535c0c69804768 Mon Sep 17 00:00:00 2001 From: Krisoye Smith Date: Mon, 2 Feb 2026 09:21:50 -0500 Subject: [PATCH] ci: enhance GitHub Actions workflow - Add workflow_dispatch for manual runs - Make lint job non-blocking with continue-on-error - Add fail-fast: false to run all matrix combinations - Add pip caching for faster builds - Add coverage threshold (80% minimum) Co-Authored-By: Claude Opus 4.5 --- .github/workflows/test.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 3cb7531..904ef74 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -4,11 +4,13 @@ on: push: branches: [main] pull_request: + workflow_dispatch: # Allow manual runs jobs: test: runs-on: ubuntu-latest strategy: + fail-fast: false # Run all matrix combinations even if one fails matrix: python-version: ['3.10', '3.11', '3.12'] @@ -19,6 +21,7 @@ jobs: uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} + cache: 'pip' - name: Install dependencies run: | @@ -27,7 +30,7 @@ jobs: - name: Run tests with coverage run: | - pytest tests/ -v --cov=src/document_analysis_mcp --cov-report=term --cov-report=xml + pytest tests/ -v --cov=src/document_analysis_mcp --cov-report=term --cov-report=xml --cov-fail-under=80 - name: Upload coverage to Codecov if: matrix.python-version == '3.12' @@ -38,6 +41,8 @@ jobs: lint: runs-on: ubuntu-latest + # Lint is non-blocking - failures are reported but don't fail the build + continue-on-error: true steps: - uses: actions/checkout@v4 @@ -45,6 +50,7 @@ jobs: uses: actions/setup-python@v5 with: python-version: '3.12' + cache: 'pip' - name: Install ruff run: pip install ruff