Merge pull request #10 from rodrigooler/q2-devnet #41
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: Q2 Validate | |
| on: | |
| push: | |
| branches: [main, q2-devnet] | |
| pull_request: | |
| jobs: | |
| validate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 | |
| - name: Setup Python | |
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 | |
| with: | |
| python-version: "3.11" | |
| cache: "pip" | |
| cache-dependency-path: | | |
| poc/requirements-dev.txt | |
| poc/requirements.txt | |
| - name: Restore Python venv cache | |
| id: cache-python-venv | |
| uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 | |
| with: | |
| path: .venv | |
| key: ${{ runner.os }}-py311-venv-${{ hashFiles('poc/requirements-dev.txt', 'poc/requirements.txt') }} | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@efa25f7f19611383d5b0ccf2d1c8914531636bf9 | |
| with: | |
| toolchain: stable | |
| - name: Restore Rust cache | |
| uses: Swatinem/rust-cache@ad397744b0d591a723ab90405b7247fac0e6b8db | |
| with: | |
| workspaces: | | |
| runtime/cognitive -> runtime/cognitive/target | |
| programs/raxion-poiq -> programs/raxion-poiq/target | |
| proofs -> proofs/target | |
| sdk/agent -> sdk/agent/target | |
| - name: Install Python deps | |
| if: steps.cache-python-venv.outputs.cache-hit != 'true' | |
| run: | | |
| python -m venv .venv | |
| . .venv/bin/activate | |
| python -m pip install --upgrade pip | |
| pip install --prefer-binary -r poc/requirements-dev.txt | |
| - name: Python tests | |
| run: | | |
| .venv/bin/pytest poc/tests/ -q | |
| - name: Runtime cognitive tests | |
| run: | | |
| cargo test --manifest-path runtime/cognitive/Cargo.toml | |
| - name: PoIQ program tests | |
| run: | | |
| cargo test --manifest-path programs/raxion-poiq/Cargo.toml | |
| - name: RISC0 types tests | |
| run: | | |
| cargo test -p risc0-types --manifest-path proofs/Cargo.toml | |
| - name: Coherence cross-validation | |
| run: | | |
| .venv/bin/python scripts/cross_validate_coherence.py | |
| - name: SDK examples | |
| run: | | |
| cargo build --manifest-path sdk/agent/Cargo.toml --example math_agent --example code_agent --example text_agent | |
| - name: Setup Node | |
| uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 | |
| with: | |
| node-version: "20" | |
| cache: "npm" | |
| cache-dependency-path: apps/explorer/package-lock.json | |
| - name: Explorer build | |
| run: | | |
| cd apps/explorer | |
| npm ci --prefer-offline --no-audit --fund=false | |
| npm run build |