Repository navigation
chore(hardening): apply C1-C9 production readiness hardening #8
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: CI | |
| on: | |
| push: | |
| branches: [master, prod-hardening] | |
| pull_request: | |
| branches: [master] | |
| permissions: | |
| contents: read | |
| jobs: | |
| validate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out source | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| cache: "pip" | |
| - name: Install system toolchains | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y --no-install-recommends \ | |
| gcc g++ gdb git cmake make \ | |
| libgl1 libegl1 libxkbcommon-x11-0 libfontconfig1 libdbus-1-3 | |
| - name: Install Python dependencies | |
| run: | | |
| python3 -m pip install --upgrade pip | |
| pip install -e .[test] | |
| - name: Validate Python syntax | |
| run: | | |
| python3 -m compileall -q medha main.py build_packages.py | |
| python3 -m py_compile medha/__main__.py | |
| - name: Verify health diagnostic CLI | |
| run: | | |
| python3 -m medha health | |
| - name: Run unit test suite with coverage gate (>=80%) | |
| run: | | |
| pytest --cov --cov-fail-under=80 | |
| - name: Run verification harness (P3 to P6) | |
| run: | | |
| python3 verify_medha_p3_p6.py | |
| - name: Run DSA visualizer verification | |
| run: | | |
| python3 verify_dsa_visualizer.py | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Build and smoke-test Docker container | |
| run: | | |
| docker build -t medha-ide:local . | |
| docker run --rm medha-ide:local health |