feat: anti bane micro #17
This file contains 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
on: | |
push: | |
branches: [ main ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
# check-out repo | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.head_ref }} | |
- name: Checkout submodules | |
run: git submodule update --init --recursive | |
# install poetry | |
- name: Install poetry | |
run: pipx install poetry | |
# set-up python with cache | |
- name: Setup Python 3.12 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
cache: 'poetry' | |
- name: Update pip | |
run: poetry run pip install -U pip | |
- name: Install requirements | |
run: poetry install --no-root | |
- name: Compile ladder zip | |
run: poetry run python scripts/create_ladder_zip.py | |
- uses: montudor/action-zip@v1 | |
with: | |
args: unzip -qq bot.zip -d out | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: ladder-zip | |
path: out | |
- name: Upload to AIArena | |
env: | |
UPLOAD_API_TOKEN: ${{ secrets.UPLOAD_API_TOKEN }} | |
UPLOAD_BOT_ID: ${{ secrets.UPLOAD_BOT_ID }} | |
run: poetry run python scripts/upload_to_ai_arena.py |