diff --git a/.github/workflows/code-quality-optimized.yml b/.github/workflows/code-quality-optimized.yml index 5787f00..42da79e 100644 --- a/.github/workflows/code-quality-optimized.yml +++ b/.github/workflows/code-quality-optimized.yml @@ -55,8 +55,8 @@ jobs: restore-keys: | ${{ runner.os }}-pip-${{ env.CACHE_VERSION }}- ${{ runner.os }}-pip- - setuptools - pip install --no-cache-dir dependencies + + - name: Install dependencies run: | python -m pip install --upgrade pip wheel pip install -r requirements.txt @@ -149,6 +149,9 @@ jobs: - name: Run optimized pytest run: | pytest \ + --cov=core \ + --cov=agents \ + --cov=autopilot \ --cov=.github/scripts \ --cov-report=xml \ --cov-report=term-missing \ @@ -203,7 +206,7 @@ jobs: - name: Run Bandit security scan run: | - bandit -r .github/scripts \ + bandit -r core/ agents/ autopilot/ .github/scripts \ -f json \ -o bandit-report.json \ --severity-level medium \ @@ -287,8 +290,8 @@ jobs: - name: Run complexity analysis run: | - radon cc .github/scripts -a -j > complexity.json - radon mi .github/scripts -j > maintainability.json + radon cc core/ agents/ autopilot/ .github/scripts -a -j > complexity.json + radon mi core/ agents/ autopilot/ .github/scripts -j > maintainability.json - name: Generate complexity report id: complexity_report diff --git a/.github/workflows/monitoring_export.yml b/.github/workflows/monitoring_export.yml index 5d4ab28..95dda4e 100644 --- a/.github/workflows/monitoring_export.yml +++ b/.github/workflows/monitoring_export.yml @@ -2,14 +2,18 @@ name: Monitoring Metrics Export on: schedule: - # Export metrics every 15 minutes - - cron: '*/15 * * * *' + # Export metrics hourly (was */15 — 96×/day causing 195+ consecutive failures) + - cron: '0 * * * *' workflow_dispatch: push: branches: [main] +concurrency: + group: monitoring-export + cancel-in-progress: true + permissions: - actions: read + actions: write contents: read env: @@ -34,6 +38,7 @@ jobs: pip install requests python-dateutil - name: Fetch workflow metrics + continue-on-error: true env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | @@ -167,6 +172,7 @@ jobs: EOF - name: Check API rate limits + continue-on-error: true env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: |