diff --git a/.github/actions/slack-notify/action.yml b/.github/actions/slack-notify/action.yml index 400a5b0482..9e95ab959d 100644 --- a/.github/actions/slack-notify/action.yml +++ b/.github/actions/slack-notify/action.yml @@ -23,19 +23,17 @@ runs: run: | echo "Parsing job results..." failed_list="" - - # Parse the JSON and extract failed jobs + echo '${{ inputs.failed-jobs }}' | jq -r 'to_entries[] | select(.value.result == "failure") | .key' | while read job; do case $job in "check-translations") failed_list="${failed_list}❌ Translation check\n" ;; "knip") failed_list="${failed_list}❌ Knip analysis\n" ;; "compile") failed_list="${failed_list}❌ Compile & lint\n" ;; - "platform-unit-test") failed_list="${failed_list}❌ Unit tests\n" ;; + "unit-test") failed_list="${failed_list}❌ Unit tests\n" ;; "integration-test") failed_list="${failed_list}❌ Integration tests\n" ;; esac done - - # Remove trailing newline and save to output + echo "failed_jobs<> $GITHUB_OUTPUT echo -e "$failed_list" | sed '/^$/d' >> $GITHUB_OUTPUT echo "EOF" >> $GITHUB_OUTPUT @@ -47,14 +45,14 @@ runs: channel: ${{ inputs.channel }} text: | 🚨 ${{ inputs.workflow-name }} workflow failed on main branch! - + Repository: ${{ github.repository }} Commit: ${{ github.sha }} Author: ${{ github.actor }} - + Failed jobs: ${{ steps.parse-jobs.outputs.failed_jobs }} - + View details: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} env: - SLACK_WEBHOOK_URL: ${{ inputs.webhook-url }} \ No newline at end of file + SLACK_WEBHOOK_URL: ${{ inputs.webhook-url }} diff --git a/.github/workflows/code-qa.yml b/.github/workflows/code-qa.yml index bca8fa0c1c..e589f416da 100644 --- a/.github/workflows/code-qa.yml +++ b/.github/workflows/code-qa.yml @@ -10,7 +10,7 @@ on: jobs: check-translations: - runs-on: ubuntu-latest + runs-on: blacksmith-4vcpu-ubuntu-2404 steps: - name: Checkout code uses: actions/checkout@v4 @@ -20,7 +20,7 @@ jobs: run: node scripts/find-missing-translations.js knip: - runs-on: ubuntu-latest + runs-on: blacksmith-4vcpu-ubuntu-2404 steps: - name: Checkout code uses: actions/checkout@v4 @@ -30,7 +30,7 @@ jobs: run: pnpm knip compile: - runs-on: ubuntu-latest + runs-on: blacksmith-4vcpu-ubuntu-2404 steps: - name: Checkout code uses: actions/checkout@v4 @@ -41,11 +41,16 @@ jobs: - name: Check types run: pnpm check-types - platform-unit-test: + unit-test: + name: platform-unit-test (${{ matrix.name }}) runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest, windows-latest] + include: + - os: blacksmith-4vcpu-ubuntu-2404 + name: ubuntu-latest + - os: windows-latest + name: windows-latest steps: - name: Checkout code uses: actions/checkout@v4 @@ -70,7 +75,7 @@ jobs: fi integration-test: - runs-on: ubuntu-latest + runs-on: blacksmith-4vcpu-ubuntu-2404 needs: [check-openrouter-api-key] if: needs.check-openrouter-api-key.outputs.exists == 'true' steps: @@ -87,7 +92,7 @@ jobs: notify-slack-on-failure: runs-on: ubuntu-latest - needs: [check-translations, knip, compile, platform-unit-test, integration-test] + needs: [check-translations, knip, compile, unit-test, integration-test] if: ${{ always() && github.event_name == 'push' && github.ref == 'refs/heads/main' && contains(needs.*.result, 'failure') }} steps: - name: Checkout code