Partners Report #43
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
name: Partners Report | |
on: | |
workflow_dispatch: | |
schedule: | |
# Wait for 1 hour of block history in the new month before starting export. | |
- cron: 0 1 1 * * | |
jobs: | |
run_partners_dot_py: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
network: [ mainnet, ftm-main ] | |
include: | |
# Providers for all chains. | |
- network: mainnet | |
label: ETH | |
provider: WEB3_PROVIDER | |
- network: ftm-main | |
label: FTM | |
provider: FTM_WEB3_PROVIDER | |
fail-fast: false | |
steps: | |
- name: Check out repository code | |
uses: actions/checkout@v3 | |
- name: Setup Python (faster than using Python container) | |
uses: actions/setup-python@v2 | |
with: | |
python-version: "3.10" | |
- name: Prep dependencies | |
run: pip install wheel && pip install "Cython<3.0" "pyyaml==5.4.1" --no-build-isolation | |
- name: Install dependencies | |
run: pip install -r requirements.txt | |
- name: Setup brownie networks | |
run: brownie networks modify ${{ matrix.network }} host=${{ secrets[matrix.provider] }} | |
- uses: actions/download-artifact@v3 | |
with: | |
name: joblib-cache | |
path: cache | |
- name: Partners Summary | |
env: | |
# Explorer tokens for all chains: | |
ETHERSCAN_TOKEN: ${{ secrets.ETHERSCAN_TOKEN }} | |
FTMSCAN_TOKEN: ${{ secrets.FTMSCAN_TOKEN }} | |
YPRICEAPI_SIGNER: ${{ secrets.YPRICEAPI_SIGNER }} | |
YPRICEAPI_SIGNATURE: ${{ secrets.YPRICEAPI_SIGNATURE }} | |
run: brownie run partners_summary --network ${{ matrix.network }} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: joblib-cache | |
path: cache | |
- name: Install Telebot | |
run: pip install pyTelegramBotAPI==4.6.0 | |
- name: Robowoofy Upload File | |
env: | |
B2B_TELEGRAM_ID: ${{ secrets.B2B_TELEGRAM_ID }} | |
TELEGRAM_TOKEN: ${{ secrets.TELEGRAM_TOKEN }} | |
run: brownie run robowoofy/post_partners --network ${{ matrix.network }} |