fix(worker-ops): recover failed workers before scheduler gating #44
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: Worker Operations CI | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| worker-tests: | |
| name: Worker Operations Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| # === COMMON SETUP === | |
| - uses: actions/checkout@v4 | |
| with: | |
| token: ${{ secrets.GH_PAT }} | |
| submodules: recursive | |
| - name: Install Flow CLI | |
| run: sh -ci "$(curl -fsSL https://raw.githubusercontent.com/onflow/flow-cli/master/install.sh)" | |
| - name: Update PATH | |
| run: echo "$HOME/.local/bin" >> $GITHUB_PATH | |
| - name: Verify Flow CLI Installation | |
| run: flow version | |
| - name: Initialize submodules | |
| run: git submodule update --init --recursive | |
| - name: Install Foundry | |
| uses: foundry-rs/foundry-toolchain@v1 | |
| with: | |
| version: stable | |
| - name: Install Solidity dependencies | |
| working-directory: ./solidity | |
| run: forge install --no-git | |
| - name: Make scripts executable | |
| run: | | |
| chmod +x ./local/setup_and_run_emulator.sh | |
| chmod +x ./local/deploy_full_stack.sh | |
| chmod +x ./local/run_worker_tests.sh | |
| # === INFRASTRUCTURE SETUP === | |
| - name: Setup and Run Emulator | |
| run: | | |
| ./local/setup_and_run_emulator.sh & | |
| sleep 80 # Wait for the emulator to be fully up | |
| - name: Deploy Full Stack | |
| run: ./local/deploy_full_stack.sh | |
| - name: Detect Strategy Identifier | |
| run: | | |
| echo "Detecting supported strategy identifier..." | |
| YIELDVAULT_CHECK=$(flow scripts execute ./cadence/scripts/check_yieldvault_details.cdc 0x045a1763c93006ca) | |
| echo "$YIELDVAULT_CHECK" | |
| SUPPORTED_STRATEGIES=$(echo "$YIELDVAULT_CHECK" | grep -oE '"supportedStrategies": \[[^]]*\]' || true) | |
| if [ -z "$SUPPORTED_STRATEGIES" ]; then | |
| echo "❌ Could not parse supported strategy list" | |
| exit 1 | |
| fi | |
| STRATEGY_LIST=$(echo "$SUPPORTED_STRATEGIES" | sed -E 's/^"supportedStrategies": \[(.*)\]$/\1/' | tr -d '"' | tr ',' '\n' | sed 's/^ *//;s/ *$//' | sed '/^$/d') | |
| STRATEGY_IDENTIFIER=$(echo "$STRATEGY_LIST" | grep 'TracerStrategy' | head -n 1 || true) | |
| if [ -z "$STRATEGY_IDENTIFIER" ]; then | |
| STRATEGY_IDENTIFIER=$(echo "$STRATEGY_LIST" | head -n 1) | |
| fi | |
| if [ -z "$STRATEGY_IDENTIFIER" ]; then | |
| echo "❌ No supported strategy identifier found" | |
| exit 1 | |
| fi | |
| echo "Using strategy identifier: $STRATEGY_IDENTIFIER" | |
| echo "STRATEGY_IDENTIFIER=$STRATEGY_IDENTIFIER" >> $GITHUB_ENV | |
| # === RUN WORKER TESTS === | |
| - name: Run Worker Tests | |
| run: ./local/run_worker_tests.sh |