chore(deps): bump @types/node from 20.12.13 to 20.19.33 in /templates/typescript #9303
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: Test Framework CLI | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| types: [opened, synchronize, reopened] | |
| merge_group: | |
| types: [checks_requested] | |
| defaults: | |
| run: | |
| working-directory: ./apps/framework-cli | |
| jobs: | |
| # Initial check for changes | |
| detect-changes: | |
| runs-on: ubuntu-latest | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| outputs: | |
| should_run: ${{ steps.check-changes.outputs.should_run }} | |
| defaults: | |
| run: | |
| working-directory: . | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| fetch-depth: 0 | |
| fetch-tags: true | |
| - name: Fetch main branch | |
| run: git fetch origin main:main | |
| - name: Check for relevant changes | |
| id: check-changes | |
| shell: bash | |
| run: | | |
| # Define patterns to check - one per line for readability | |
| PATTERNS=( | |
| "^\.github/workflows/test-framework-cli\.yaml" | |
| "^\.github/scripts/check-cli-dependencies\.sh" | |
| "^apps/framework-cli-e2e/" | |
| "^apps/framework-cli/" | |
| "^templates/python" | |
| "^templates/typescript" | |
| "^packages/" | |
| "Cargo.lock" | |
| ) | |
| # Join patterns with | for grep | |
| GREP_PATTERN=$(IFS="|"; echo "${PATTERNS[*]}") | |
| # Get changed files between main and current branch | |
| git diff --name-only origin/main...HEAD > changes.txt | |
| echo "::group::🔍 All Changed Files" | |
| cat changes.txt | |
| echo "::endgroup::" | |
| echo "::group::📋 Files Matching Patterns (excluding pnpm-lock.yaml)" | |
| echo "Looking for files matching these patterns:" | |
| printf '%s\n' "${PATTERNS[@]}" | |
| echo "---" | |
| echo "Matching files:" | |
| grep -E "${GREP_PATTERN}" changes.txt || echo "No files match patterns" | |
| echo "::endgroup::" | |
| # Check if any relevant files were changed (excluding pnpm-lock) | |
| if grep -q -E "${GREP_PATTERN}" changes.txt; then | |
| echo "::notice title=✅ Running Tests::Detected relevant changes in the codebase. Tests will run." | |
| echo "should_run=true" >> $GITHUB_OUTPUT | |
| # If only pnpm-lock.yaml changed, use smart analysis | |
| elif grep -q "pnpm-lock.yaml" changes.txt; then | |
| echo "::notice title=🔍 Analyzing Dependencies::Only pnpm-lock.yaml changed, checking if CLI is affected..." | |
| if .github/scripts/check-cli-dependencies.sh; then | |
| echo "::notice title=✅ Running Tests::pnpm-lock.yaml changes affect CLI packages. Tests will run." | |
| echo "should_run=true" >> $GITHUB_OUTPUT | |
| else | |
| echo "::notice title=⏭️ Skipping Tests::pnpm-lock.yaml changes don't affect CLI packages. Tests will be skipped." | |
| echo "should_run=false" >> $GITHUB_OUTPUT | |
| fi | |
| else | |
| echo "::notice title=⏭️ Skipping Tests::No relevant changes detected. Tests will be skipped." | |
| echo "should_run=false" >> $GITHUB_OUTPUT | |
| fi | |
| check: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Check | |
| # This is doing both checks and compilation hence why there is a | |
| # Bigger machine | |
| runs-on: blacksmith-8vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout sources | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run cargo check | |
| run: cargo check | |
| - name: Check for unused dependencies | |
| uses: bnjbvr/cargo-machete@v0.9.1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Run cargo Build in release mode | |
| run: cargo build --release --locked | |
| test-cli: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test CLI (${{ matrix.os }}) | |
| runs-on: ${{ matrix.os }} | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [blacksmith-4vcpu-ubuntu-2404, macos-latest-large] | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run pnpm install | |
| run: pnpm install --filter=@repo/scripts # for package-templates.js | |
| - name: Run CLI Tests | |
| run: cargo test | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-ts-moose-lib: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test TS Moose Lib (Node ${{ matrix.node-version }}) | |
| runs-on: blacksmith-2vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| node-version: [20, 22, 24] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: "pnpm" | |
| - name: Run ts moose lib tests | |
| run: pnpm install --frozen-lockfile && pnpm --filter=@514labs/moose-lib run test | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| test-py-moose-lib: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test Py Moose Lib (Python ${{ matrix.python-version }}) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.12", "3.13"] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - name: Setup Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Run py moose lib tests | |
| working-directory: ./packages/py-moose-lib | |
| run: | | |
| pip install --upgrade pip setuptools wheel | |
| pip install -r requirements-dev.txt | |
| pip install -e . | |
| python -c "import moose_lib" | |
| python -m pytest tests/ | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| test-e2e-module-compilation: | |
| needs: [detect-changes, check, test-cli, test-ts-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Module Compilation (ESM/CJS) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run Module Compilation E2E Tests | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "Module Compilation" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log || true | |
| test-e2e-typescript-default: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E TypeScript Default Template (Node ${{ matrix.node-version }}, ${{ matrix.package-manager }}) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| node-version: [20, 22, 24] | |
| package-manager: [npm, pnpm-9, pnpm-10] | |
| include: | |
| - package-manager: npm | |
| pm-name: npm | |
| pm-version: "9.9.0" | |
| - package-manager: pnpm-9 | |
| pm-name: pnpm | |
| pm-version: "9.9.0" | |
| - package-manager: pnpm-10 | |
| pm-name: pnpm | |
| pm-version: "10.15.0" | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| # Update packageManager field to match matrix version for testing | |
| - name: Update pnpm version in package.json | |
| if: startsWith(matrix.package-manager, 'pnpm') | |
| working-directory: . | |
| run: | | |
| jq '.packageManager = "pnpm@${{ matrix.pm-version }}"' package.json > package.json.tmp | |
| mv package.json.tmp package.json | |
| # Setup pnpm (uses version from package.json) | |
| # For npm tests: uses monorepo's default (9.9.0) | |
| # For pnpm tests: uses matrix version (9.9.0 or 10.15.0) | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run TypeScript E2E Tests (Default Template) | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "typescript template default" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| TEST_PACKAGE_MANAGER: ${{ matrix.pm-name }} | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-typescript-tests: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E TypeScript Tests Template (Node ${{ matrix.node-version }}, ${{ matrix.package-manager }}) | |
| runs-on: blacksmith-8vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| node-version: [20, 22, 24] | |
| package-manager: [npm] | |
| include: | |
| - package-manager: npm | |
| pm-name: npm | |
| pm-version: bundled | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run TypeScript E2E Tests (Tests Template) | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "typescript template tests" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| TEST_PACKAGE_MANAGER: ${{ matrix.pm-name }} | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-python-default: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Python Default Template (Python ${{ matrix.python-version }}) | |
| runs-on: blacksmith-8vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.12", "3.13"] | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Setup Python ${{ matrix.python-version }} for E2E tests | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Upgrade Python build tools | |
| run: pip install --upgrade pip setuptools wheel | |
| - name: Run Python E2E Tests (Default Template) | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "python template default" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| TEST_PACKAGE_MANAGER: pip | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-python-tests: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Python Tests Template (Python ${{ matrix.python-version }}) | |
| runs-on: blacksmith-8vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.12", "3.13"] | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Setup Python ${{ matrix.python-version }} for E2E tests | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Upgrade Python build tools | |
| run: pip install --upgrade pip setuptools wheel | |
| - name: Run Python E2E Tests (Tests Template) | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "python template tests" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| TEST_PACKAGE_MANAGER: pip | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-backward-compatibility-typescript: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Backward Compatibility - TypeScript (Node 20) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run TypeScript Backward Compatibility Test | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "TypeScript Tests Template - Upgrade" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| # Add test credentials for S3Queue tests | |
| TEST_AWS_ACCESS_KEY_ID: "test-access-key-id" | |
| TEST_AWS_SECRET_ACCESS_KEY: "test-secret-access-key" | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-backward-compatibility-python: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Backward Compatibility - Python (Python 3.13) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Setup Python 3.13 for E2E tests | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: "3.13" | |
| - name: Upgrade Python build tools | |
| run: pip install --upgrade pip setuptools wheel | |
| - name: Run Python Backward Compatibility Test | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "Python Tests Template - Upgrade" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| # Add test credentials for S3Queue tests | |
| TEST_AWS_ACCESS_KEY_ID: "test-access-key-id" | |
| TEST_AWS_SECRET_ACCESS_KEY: "test-secret-access-key" | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-cluster-typescript: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Cluster Support - TypeScript (Node 20) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run TypeScript Cluster E2E Tests | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "TypeScript Cluster Template" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-cluster-python: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E Cluster Support - Python (Python 3.13) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Setup Python 3.13 | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: "3.13" | |
| - name: Upgrade Python build tools | |
| run: pip install --upgrade pip setuptools wheel | |
| - name: Run Python Cluster E2E Tests | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "Python Cluster Template" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| test-e2e-otlp-export: | |
| needs: | |
| [detect-changes, check, test-cli, test-ts-moose-lib, test-py-moose-lib] | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Test E2E OTLP Log Export (TypeScript) | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| permissions: | |
| contents: read | |
| env: | |
| RUST_BACKTRACE: full | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| # Login to Docker hub to get higher rate limits when moose pulls images | |
| - name: Login to Docker Hub | |
| uses: ./.github/actions/docker-login | |
| with: | |
| op-service-account-token: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| - name: Install node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: "pnpm" | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| cache: true | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| - name: Run OTLP Export E2E Tests | |
| run: pnpm install --frozen-lockfile && pnpm --filter=framework-cli-e2e run test -- --grep "OTLP" | |
| env: | |
| MOOSE_TELEMETRY_ENABLED: false | |
| - name: Inspect Logs | |
| if: always() | |
| run: | | |
| cat ~/.moose/*-cli.log | |
| lints: | |
| needs: detect-changes | |
| if: needs.detect-changes.outputs.should_run == 'true' | |
| name: Lints | |
| runs-on: blacksmith-4vcpu-ubuntu-2404 | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Install Protoc (Needed for Temporal) | |
| uses: arduino/setup-protoc@v3 | |
| with: | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| version: "23.x" | |
| - name: Checkout sources | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| components: rustfmt, clippy | |
| cache: true | |
| # Simplified key: OS + arch is sufficient, Cargo.lock hash is added automatically | |
| # This allows cache sharing across all Linux/macOS jobs in this workflow | |
| cache-shared-key: ${{ runner.os }}-${{ runner.arch }}-rust | |
| cache-on-failure: true | |
| cache-all-crates: true | |
| cache-workspace-crates: true | |
| # to trigger code gen | |
| - name: Run cargo build | |
| run: cargo build | |
| - name: Run cargo fmt | |
| run: cargo fmt --all -- --check | |
| - name: Run cargo clippy | |
| run: cargo clippy --all-targets -- -D warnings | |
| # Final status check that depends on all jobs | |
| changes: | |
| runs-on: ubuntu-latest | |
| needs: | |
| [ | |
| detect-changes, | |
| check, | |
| test-cli, | |
| test-ts-moose-lib, | |
| test-py-moose-lib, | |
| test-e2e-module-compilation, | |
| test-e2e-typescript-default, | |
| test-e2e-typescript-tests, | |
| test-e2e-python-default, | |
| test-e2e-python-tests, | |
| # test-e2e-backward-compatibility-typescript, | |
| test-e2e-backward-compatibility-python, | |
| test-e2e-cluster-typescript, | |
| test-e2e-cluster-python, | |
| test-e2e-otlp-export, | |
| lints, | |
| ] | |
| if: always() | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| defaults: | |
| run: | |
| working-directory: . | |
| steps: | |
| - name: Check final status | |
| shell: bash | |
| run: | | |
| if [[ "${{ needs.detect-changes.outputs.should_run }}" == "false" ]]; then | |
| echo "No relevant changes detected, marking as success" | |
| exit 0 | |
| fi | |
| # Check if any required jobs failed | |
| if [[ "${{ needs.check.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-cli.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-ts-moose-lib.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-py-moose-lib.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-module-compilation.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-typescript-default.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-typescript-tests.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-python-default.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-python-tests.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-backward-compatibility-python.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-cluster-typescript.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-cluster-python.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.test-e2e-otlp-export.result }}" == "failure" ]] || \ | |
| [[ "${{ needs.lints.result }}" == "failure" ]]; then | |
| echo "One or more required jobs failed" | |
| exit 1 | |
| fi | |
| if [[ "${{ needs.check.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-cli.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-ts-moose-lib.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-py-moose-lib.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-module-compilation.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-typescript-default.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-typescript-tests.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-python-default.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-python-tests.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-backward-compatibility-python.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-cluster-typescript.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-cluster-python.result }}" == "success" ]] && \ | |
| [[ "${{ needs.test-e2e-otlp-export.result }}" == "success" ]] && \ | |
| [[ "${{ needs.lints.result }}" == "success" ]]; then | |
| echo "All required jobs succeeded" | |
| exit 0 | |
| fi | |
| echo "Unexpected state in dependent jobs" | |
| exit 1 | |
| notify-slack-on-failure: | |
| needs: [changes] | |
| runs-on: ubuntu-latest | |
| # Add explicit read-only permissions | |
| permissions: | |
| contents: read | |
| if: failure() && github.ref == 'refs/heads/main' | |
| defaults: | |
| run: | |
| working-directory: . | |
| steps: | |
| - name: Notify Slack on failure | |
| uses: 514-labs/slack-notification-action@1.0.0 | |
| with: | |
| slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }} | |
| slack-webhook-url: ${{ secrets.SLACK_GITHUB_ACTIONS_WEBHOOK_URL }} |