chore(deps): bump fast-uri from 3.1.0 to 3.1.2 #95
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
| # DCP-AI Continuous Integration | |
| # Runs conformance tests and bundle verification on every push/PR. | |
| name: DCP-AI CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| # Least-privilege default. Jobs can override with a narrower or wider scope | |
| # as needed (e.g. codecov/codecov-action@v4 does not require any write perms). | |
| permissions: | |
| contents: read | |
| jobs: | |
| # Detect which areas changed so per-language suites can skip when untouched. | |
| # Conformance always runs — it's the wire-format invariant check that should | |
| # catch any protocol-level regression, regardless of which SDK was edited. | |
| changes: | |
| name: Detect changes | |
| runs-on: ubuntu-latest | |
| outputs: | |
| typescript: ${{ steps.filter.outputs.typescript }} | |
| python: ${{ steps.filter.outputs.python }} | |
| go: ${{ steps.filter.outputs.go }} | |
| rust: ${{ steps.filter.outputs.rust }} | |
| wasm: ${{ steps.filter.outputs.wasm }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dorny/paths-filter@v3 | |
| id: filter | |
| with: | |
| filters: | | |
| typescript: | |
| - 'sdks/typescript/**' | |
| - 'schemas/**' | |
| - 'spec/**' | |
| - 'tests/**' | |
| - 'package.json' | |
| - 'package-lock.json' | |
| - '.github/workflows/ci.yml' | |
| python: | |
| - 'sdks/python/**' | |
| - 'schemas/**' | |
| - 'spec/**' | |
| - 'tests/**' | |
| - '.github/workflows/ci.yml' | |
| go: | |
| - 'sdks/go/**' | |
| - 'schemas/**' | |
| - 'spec/**' | |
| - 'tests/**' | |
| - '.github/workflows/ci.yml' | |
| rust: | |
| - 'sdks/rust/**' | |
| - 'sdks/wasm/**' | |
| - 'schemas/**' | |
| - 'spec/**' | |
| - 'tests/**' | |
| - '.github/workflows/ci.yml' | |
| wasm: | |
| - 'sdks/wasm/**' | |
| - 'sdks/rust/**' | |
| - 'schemas/**' | |
| - 'spec/**' | |
| - '.github/workflows/ci.yml' | |
| conformance: | |
| name: Conformance Tests | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node-version: [20, 22] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| - name: Install dependencies | |
| run: npm install | |
| - name: Run conformance tests (V1 + V2) | |
| run: npm run conformance | |
| - name: Generate V2 examples | |
| run: npm run examples:generate:v2 | |
| - name: Verify example signed bundle (V1) | |
| run: | | |
| if [ -f tests/conformance/examples/citizenship_bundle.signed.json ] && [ -f keys/public_key.txt ]; then | |
| node bin/dcp.js verify-bundle tests/conformance/examples/citizenship_bundle.signed.json keys/public_key.txt | |
| else | |
| echo "Skipping V1 bundle verification (missing test files)" | |
| fi | |
| - name: Verify V2 signed bundle | |
| run: | | |
| if [ -f tests/conformance/examples/signed_bundle_v2.json ]; then | |
| echo "V2 signed bundle exists — structural check passed" | |
| node -e " | |
| const fs = require('fs'); | |
| const b = JSON.parse(fs.readFileSync('tests/conformance/examples/signed_bundle_v2.json','utf8')); | |
| console.log(' dcp_version:', b.dcp_version); | |
| console.log(' has manifest:', !!b.bundle_manifest); | |
| console.log(' binding:', b.signature?.binding); | |
| console.log(' session_nonce:', b.session_nonce ? 'present' : 'missing'); | |
| if (b.dcp_version !== '2.0') process.exit(1); | |
| if (!b.bundle_manifest) process.exit(1); | |
| if (!b.session_nonce) process.exit(1); | |
| " | |
| else | |
| echo "Skipping V2 bundle verification (not yet generated)" | |
| fi | |
| - name: Check protocol integrity | |
| run: node bin/dcp.js integrity | |
| typescript-sdk: | |
| name: TypeScript SDK | |
| needs: changes | |
| if: ${{ needs.changes.outputs.typescript == 'true' }} | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: sdks/typescript | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - name: Install dependencies | |
| run: npm install | |
| - name: Type check | |
| run: npx tsc --noEmit | |
| - name: Build | |
| run: npm run build | |
| - name: Run tests | |
| run: npm run test | |
| - name: Code coverage | |
| run: npm run test:coverage | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| files: ./sdks/typescript/coverage/lcov.info | |
| flags: sdk-typescript | |
| fail_ci_if_error: false | |
| disable_search: true | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
| python-sdk: | |
| name: Python SDK | |
| needs: changes | |
| if: ${{ needs.changes.outputs.python == 'true' }} | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: sdks/python | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Install dependencies | |
| run: pip install -e ".[dev]" pytest-cov coverage | |
| - name: Run tests with coverage | |
| run: pytest -v --cov=dcp_ai --cov-report=xml --cov-report=term | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| files: ./sdks/python/coverage.xml | |
| flags: sdk-python | |
| fail_ci_if_error: false | |
| disable_search: true | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
| go-sdk: | |
| name: Go SDK | |
| needs: changes | |
| if: ${{ needs.changes.outputs.go == 'true' }} | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: sdks/go | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: "1.22" | |
| - name: Build | |
| run: go build ./... | |
| - name: Test with coverage | |
| run: go test -coverprofile=coverage.out -covermode=atomic ./... | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| files: ./sdks/go/coverage.out | |
| flags: sdk-go | |
| fail_ci_if_error: false | |
| disable_search: true | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
| rust-sdk: | |
| name: Rust SDK | |
| needs: changes | |
| if: ${{ needs.changes.outputs.rust == 'true' }} | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: sdks/rust | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: llvm-tools-preview | |
| - name: Install cargo-llvm-cov | |
| uses: taiki-e/install-action@cargo-llvm-cov | |
| - name: Build | |
| run: cargo build | |
| - name: Test with coverage | |
| run: cargo llvm-cov --lcov --output-path lcov.info | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| files: ./sdks/rust/lcov.info | |
| flags: sdk-rust | |
| fail_ci_if_error: false | |
| disable_search: true | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
| - name: Build WASM | |
| run: | | |
| rustup target add wasm32-unknown-unknown | |
| cargo build --target wasm32-unknown-unknown --features wasm | |
| wasm-sdk: | |
| name: WASM SDK | |
| needs: changes | |
| if: ${{ needs.changes.outputs.wasm == 'true' }} | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: sdks/wasm | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - name: Install wasm-pack | |
| run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - name: Build WASM | |
| run: npm run build:wasm | |
| - name: Build TypeScript | |
| run: | | |
| npm install | |
| npm run build:ts |