From b269c44a2ac0014d0428dfd269acc4d46623ef58 Mon Sep 17 00:00:00 2001 From: Alberto Monterroso <14013679+Albermonte@users.noreply.github.com> Date: Fri, 29 Nov 2024 11:15:30 -0600 Subject: [PATCH] chore: re-calculate scores action --- .github/workflows/sync.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index de72c46..30c243f 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -84,3 +84,21 @@ jobs: fi echo $RESPONSE + + sync-validator-scores: + name: Recalculates the validators score + strategy: + fail-fast: false + runs-on: ubuntu-latest + steps: + - name: Sync validator scores + run: | + echo "Sync validators scores for ${{ inputs.network }}..." + RESPONSE=$(curl -s -X POST "${{ inputs.api_url }}/api/v1/scores?force=true") + + ISSUES=$(echo $RESPONSE | jq -r '.issues') + if [ "$ISSUES" != "[]" ]; then + echo "Issues found: $ISSUES" + fi + + echo $RESPONSE