add buyCollateral script and add setTargetReserves function for lending contract

This commit is contained in:
2026-01-08 11:30:31 +08:00
parent c8cb4dbecd
commit a18b9a42e4
19 changed files with 713 additions and 1221 deletions

View File

@@ -1,8 +1,8 @@
import hre from 'hardhat';
import { Signer } from 'ethers';
const LOOKBACK_BLOCKS = 50000; // 查询最近 50000 个区块
const LIQUIDATION_THRESHOLD = 10; // $10 的最小清算阈值(美元单位)
const LOOKBACK_BLOCKS = 10000; // 查询最近 50000 个区块
const LIQUIDATION_THRESHOLD = 1; // $10 的最小清算阈值(美元单位)
/**
* 获取最近活跃的地址(通过多个事件)