Phase 0 & Phase 1 Complete: Security fixes and quality improvements #1
Workflow file for this run
This file contains hidden or 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: Quality Check | |
| on: | |
| push: | |
| branches: [ main, develop, claude/** ] | |
| pull_request: | |
| branches: [ main, develop ] | |
| jobs: | |
| test: | |
| name: Run Tests | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: ["3.10", "3.11"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: 'pip' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| pip install pytest pytest-cov pytest-asyncio pytest-mock | |
| - name: Run tests with coverage | |
| run: | | |
| pytest --cov=aiops --cov-report=xml --cov-report=term | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v3 | |
| with: | |
| file: ./coverage.xml | |
| flags: unittests | |
| name: codecov-umbrella | |
| fail_ci_if_error: false | |
| lint: | |
| name: Code Quality | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| cache: 'pip' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install black flake8 mypy isort pylint | |
| - name: Run Black | |
| run: black --check aiops/ | |
| - name: Run Flake8 | |
| run: flake8 aiops/ | |
| - name: Run isort | |
| run: isort --check-only aiops/ | |
| - name: Run MyPy | |
| run: mypy aiops/ --ignore-missing-imports | |
| continue-on-error: true | |
| - name: Run Pylint | |
| run: pylint aiops/ --fail-under=7.0 --disable=all --enable=E,F,W | |
| continue-on-error: true |