Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/run-bot-aib-tournament.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1545,6 +1545,7 @@ jobs:
uses: ./.github/workflows/run-bot-launcher.yaml
with:
bot_name: "METAC_UNIFORM_PROBABILITY_BOT_TOKEN"
metac_name: "metac-uniform-probability-bot"
cache_key: asknews-cache-${{ github.run_id }}
secrets:
INPUT_METACULUS_TOKENS: ${{ secrets.METACULUS_TOKENS }}
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/run-bot-launcher.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ on:
bot_name:
required: true
type: string
metac_name:
required: false
type: string
default: ""
cache_key:
required: false
type: string
Expand Down Expand Up @@ -119,17 +123,17 @@ jobs:
if [ -n "$RAW_TOKEN" ]; then
echo "METACULUS_TOKEN=$RAW_TOKEN" >> $GITHUB_ENV
else
TOKEN=$(echo "$METACULUS_TOKENS" | jq -r --arg key "$BOT_NAME" '.[$key] // empty')
TOKEN=$(echo "$METACULUS_TOKENS" | jq -r --arg key "$METAC_NAME" '.[$key] // empty')
if [ -z "$TOKEN" ]; then
echo "ERROR: No token found for $BOT_NAME in METACULUS_TOKENS" >&2
echo "ERROR: No token found for $METAC_NAME in METACULUS_TOKENS" >&2
exit 1
Comment on lines 125 to 129
fi
echo "METACULUS_TOKEN=$TOKEN" >> $GITHUB_ENV
fi
env:
RAW_TOKEN: ${{ secrets.INPUT_METACULUS_TOKEN }}
METACULUS_TOKENS: ${{ secrets.INPUT_METACULUS_TOKENS }}
BOT_NAME: ${{ inputs.bot_name }}
METAC_NAME: ${{ inputs.metac_name }}

- name: Run bot
run: |
Expand Down
Loading