mirror of
https://github.com/Instadapp/aave-protocol-v2.git
synced 2024-07-29 21:47:30 +00:00
Use registry address. Fix Provider verify. Fix WalletProvider verify.
This commit is contained in:
parent
57ee9e0a7c
commit
7bd0e9afd1
|
@ -18,6 +18,7 @@ import {
|
||||||
} from '../../helpers/contracts-getters';
|
} from '../../helpers/contracts-getters';
|
||||||
import { getParamPerNetwork } from '../../helpers/contracts-helpers';
|
import { getParamPerNetwork } from '../../helpers/contracts-helpers';
|
||||||
import { verifyContract } from '../../helpers/etherscan-verification';
|
import { verifyContract } from '../../helpers/etherscan-verification';
|
||||||
|
import { notFalsyOrZeroAddress } from '../../helpers/misc-utils';
|
||||||
import { eEthereumNetwork, ICommonConfiguration } from '../../helpers/types';
|
import { eEthereumNetwork, ICommonConfiguration } from '../../helpers/types';
|
||||||
|
|
||||||
task('verify:general', 'Deploy oracles for dev enviroment')
|
task('verify:general', 'Deploy oracles for dev enviroment')
|
||||||
|
@ -27,10 +28,18 @@ task('verify:general', 'Deploy oracles for dev enviroment')
|
||||||
await localDRE.run('set-DRE');
|
await localDRE.run('set-DRE');
|
||||||
const network = localDRE.network.name as eEthereumNetwork;
|
const network = localDRE.network.name as eEthereumNetwork;
|
||||||
const poolConfig = loadPoolConfig(pool);
|
const poolConfig = loadPoolConfig(pool);
|
||||||
const {ReserveAssets, ReservesConfig} = poolConfig as ICommonConfiguration;
|
const {
|
||||||
|
ReserveAssets,
|
||||||
|
ReservesConfig,
|
||||||
|
ProviderRegistry,
|
||||||
|
MarketId,
|
||||||
|
} = poolConfig as ICommonConfiguration;
|
||||||
|
|
||||||
|
const registryAddress = getParamPerNetwork(ProviderRegistry, network);
|
||||||
const addressesProvider = await getLendingPoolAddressesProvider();
|
const addressesProvider = await getLendingPoolAddressesProvider();
|
||||||
const addressesProviderRegistry = await getLendingPoolAddressesProviderRegistry();
|
const addressesProviderRegistry = notFalsyOrZeroAddress(registryAddress)
|
||||||
|
? await getLendingPoolAddressesProviderRegistry(registryAddress)
|
||||||
|
: await getLendingPoolAddressesProviderRegistry();
|
||||||
const lendingPoolProxy = await getLendingPool();
|
const lendingPoolProxy = await getLendingPool();
|
||||||
const lendingPoolConfigurator = await getLendingPoolConfiguratorProxy();
|
const lendingPoolConfigurator = await getLendingPoolConfiguratorProxy();
|
||||||
const lendingPoolCollateralManager = await getLendingPoolCollateralManager();
|
const lendingPoolCollateralManager = await getLendingPoolCollateralManager();
|
||||||
|
@ -45,7 +54,7 @@ task('verify:general', 'Deploy oracles for dev enviroment')
|
||||||
|
|
||||||
// Address Provider
|
// Address Provider
|
||||||
console.log('\n- Verifying address provider...\n');
|
console.log('\n- Verifying address provider...\n');
|
||||||
await verifyContract(addressesProvider.address, []);
|
await verifyContract(addressesProvider.address, [MarketId]);
|
||||||
|
|
||||||
// Address Provider Registry
|
// Address Provider Registry
|
||||||
console.log('\n- Verifying address provider registry...\n');
|
console.log('\n- Verifying address provider registry...\n');
|
||||||
|
@ -69,7 +78,7 @@ task('verify:general', 'Deploy oracles for dev enviroment')
|
||||||
|
|
||||||
// Wallet balance provider
|
// Wallet balance provider
|
||||||
console.log('\n- Verifying Wallet Balance Provider...\n');
|
console.log('\n- Verifying Wallet Balance Provider...\n');
|
||||||
await verifyContract(walletProvider.address, [addressesProvider.address]);
|
await verifyContract(walletProvider.address, []);
|
||||||
|
|
||||||
// WETHGateway
|
// WETHGateway
|
||||||
console.log('\n- Verifying WETHGateway...\n');
|
console.log('\n- Verifying WETHGateway...\n');
|
||||||
|
|
Loading…
Reference in New Issue
Block a user