Live-log scroll fix (route C), linter pins, basis notation, monospace + test-isolation fixes #94
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: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| # ── Linux: full suite including PySCF-dependent tests ───────────────────── | |
| test-linux: | |
| name: Tests (ubuntu-latest, Python ${{ matrix.python-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.9", "3.10", "3.11"] | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: pip | |
| - name: Install package and dev dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -e ".[pyscf,ase,dev]" | |
| - name: Run tests (skip network tests) | |
| run: | | |
| pytest -m "not network" \ | |
| --cov=quantui \ | |
| --cov-report=term-missing \ | |
| --cov-report=xml \ | |
| --no-header -q | |
| - name: Upload coverage to Codecov | |
| if: matrix.python-version == '3.11' | |
| uses: codecov/codecov-action@v6 | |
| with: | |
| files: coverage.xml | |
| fail_ci_if_error: false | |
| # ── Windows: non-PySCF tests only (PySCF requires Linux/WSL) ────────────── | |
| test-windows: | |
| name: Tests (windows-latest, Python 3.11) | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Python 3.11 | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.11" | |
| cache: pip | |
| - name: Install package and dev dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -e ".[ase,dev]" | |
| - name: Run non-PySCF tests | |
| # PySCF tests are skipped automatically via skipif guards when pyscf | |
| # is not installed. network tests also skipped. | |
| # Single line: PowerShell does not support backslash line continuation. | |
| run: pytest -m "not network" --ignore=tests/test_session_calc.py --ignore=tests/test_optimizer.py --ignore=tests/test_preopt.py --no-cov --no-header -q | |
| # ── Lint / type-check ───────────────────────────────────────────────────── | |
| lint: | |
| name: Lint & type check | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Python 3.11 | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.11" | |
| cache: pip | |
| - name: Install pre-commit | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install pre-commit | |
| - name: Run pre-commit (black + ruff + mypy) | |
| run: pre-commit run --all-files |