fix: send snapshots in batches for faster initial page loads #84
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: | |
| jobs: | |
| rust: | |
| name: Rust | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install protoc | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y protobuf-compiler | |
| protoc --version | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: clippy | |
| - name: Cache cargo registry | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cargo/registry | |
| ~/.cargo/git | |
| target | |
| key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-cargo- | |
| - name: Check | |
| run: cargo check --workspace | |
| - name: Test | |
| run: cargo test --workspace | |
| - name: Clippy | |
| run: cargo clippy --workspace -- -D warnings | |
| typescript-core: | |
| name: TypeScript Core | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: typescript/core | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: typescript/core/package-lock.json | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build | |
| run: npm run build | |
| - name: Test | |
| run: npm test | |
| typescript-react: | |
| name: TypeScript React | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Build core dependency | |
| working-directory: typescript/core | |
| run: npm ci && npm run build | |
| - name: Install dependencies | |
| working-directory: typescript/react | |
| run: npm ci | |
| - name: Build | |
| working-directory: typescript/react | |
| run: npm run build | |
| - name: Test | |
| working-directory: typescript/react | |
| run: npm test | |
| typescript-stacks: | |
| name: TypeScript Stacks | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: stacks/sdk/typescript | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: stacks/sdk/typescript/package-lock.json | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build | |
| run: npm run build | |
| python: | |
| name: Python | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: python/hyperstack-sdk | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install package | |
| run: pip install -e . | |
| - name: Install test dependencies | |
| run: pip install pytest | |
| # continue-on-error: true | |
| - name: Run tests | |
| run: pytest || echo "No tests found or tests skipped" | |
| # continue-on-error: true | |
| docs: | |
| name: Docs | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: docs | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: docs/package-lock.json | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Check types | |
| run: npm run check | |
| - name: Lint | |
| run: npm run lint | |
| - name: Build | |
| run: npm run build |