-
Notifications
You must be signed in to change notification settings - Fork 50
/
tend_auto.py
27 lines (21 loc) · 1011 Bytes
/
tend_auto.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
from helpers.time_utils import to_minutes
from helpers.run_persistent import run_persistent
from config.keeper import keeper_config
from helpers.utils import val
from brownie import *
from helpers.gas_utils import gas_strategies
from rich.console import Console
from scripts.systems.badger_system import BadgerSystem, connect_badger
from tabulate import tabulate
from scripts.keeper.tend import tend_all
gas_strategies.set_default_for_active_chain()
console = Console()
def main():
badger = connect_badger(load_keeper=True, load_harvester=True)
skip = keeper_config.get_active_chain_skipped_setts("tend")
run_interval = keeper_config.get_active_chain_run_interval("tend")
console.print("=== Tend (Eternal) ===")
console.print("All Setts on chain", badger.getAllSettIds())
console.print("Setts to skip", skip)
console.print("Interval between runs: {} minutes".format(to_minutes(run_interval)))
run_persistent(tend_all, (badger, skip), num_args=2, run_interval=run_interval)