Skip to content

Commit

Permalink
fix: readd harmony (#436)
Browse files Browse the repository at this point in the history
* fix: readd harmony

* fix: update scripts
  • Loading branch information
sakulstra authored Apr 23, 2024
1 parent b71481b commit cc7b565
Show file tree
Hide file tree
Showing 7 changed files with 352 additions and 20 deletions.
7 changes: 2 additions & 5 deletions scripts/generateAddresses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ async function main() {
scrollSepoliaProtoV3,
fantomTestnetProtoV3,
fantomProtoV3,
// harmonyProtoV3,
harmonyProtoV3,
].map((config) => generateProtocolV3Library(config)),
);

Expand Down Expand Up @@ -162,10 +162,7 @@ async function main() {
abis,
].flat();

const jsExports = [
...imports.map((f) => f.js).flat(),
"export * as AaveV3Harmony from './AaveV3Harmony';",
];
const jsExports = imports.map((f) => f.js).flat();
writeFileSync(`./src/ts/AaveAddressBook.ts`, prefixWithGeneratedWarning(''));
jsExports.map((jsExport) => appendFileSync('./src/ts/AaveAddressBook.ts', `${jsExport}\n`));

Expand Down
1 change: 1 addition & 0 deletions src/AaveAddressBook.sol
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ import {AaveV3Scroll} from './AaveV3Scroll.sol';
import {AaveV3ScrollSepolia} from './AaveV3ScrollSepolia.sol';
import {AaveV3FantomTestnet} from './AaveV3FantomTestnet.sol';
import {AaveV3Fantom} from './AaveV3Fantom.sol';
import {AaveV3Harmony} from './AaveV3Harmony.sol';
import {MiscArbitrum} from './MiscArbitrum.sol';
import {MiscArbitrumSepolia} from './MiscArbitrumSepolia.sol';
import {MiscAvalanche} from './MiscAvalanche.sol';
Expand Down
13 changes: 8 additions & 5 deletions src/AaveV3Harmony.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,19 @@ library AaveV3Harmony {
// https://explorer.harmony.one/address/0x794a61358D6845594F94dc1DB02A252b5b4814aD
IPool internal constant POOL = IPool(0x794a61358D6845594F94dc1DB02A252b5b4814aD);

// https://explorer.harmony.one/address/0xDF9e4ABdbd94107932265319479643D3B05809dc
address internal constant POOL_IMPL = 0xDF9e4ABdbd94107932265319479643D3B05809dc;

// https://explorer.harmony.one/address/0x8145eddDf43f50276641b55bd3AD95944510021E
IPoolConfigurator internal constant POOL_CONFIGURATOR =
IPoolConfigurator(0x8145eddDf43f50276641b55bd3AD95944510021E);

// https://explorer.harmony.one/address/0xD6FA681E22306b0F4E605B979b7c9a1dFa865ade
address internal constant POOL_CONFIGURATOR_IMPL = 0xD6FA681E22306b0F4E605B979b7c9a1dFa865ade;

// https://explorer.harmony.one/address/0x3C90887Ede8D65ccb2777A5d577beAb2548280AD
IAaveOracle internal constant ORACLE = IAaveOracle(0x3C90887Ede8D65ccb2777A5d577beAb2548280AD);

// https://explorer.harmony.one/address/0x0000000000000000000000000000000000000000
address internal constant PRICE_ORACLE_SENTINEL = 0x0000000000000000000000000000000000000000;

// https://explorer.harmony.one/address/0x69FA688f1Dc47d4B5d8029D5a35FB7a548310654
IPoolDataProvider internal constant AAVE_PROTOCOL_DATA_PROVIDER =
IPoolDataProvider(0x69FA688f1Dc47d4B5d8029D5a35FB7a548310654);
Expand Down Expand Up @@ -62,8 +65,8 @@ library AaveV3Harmony {
// https://explorer.harmony.one/address/0xf7a60467aBb8A3240A0382b22E1B03c7d4F59Da5
address internal constant UI_INCENTIVE_DATA_PROVIDER = 0xf7a60467aBb8A3240A0382b22E1B03c7d4F59Da5;

// https://explorer.harmony.one/address/0x1DcDA4de2Bf6c7AD9a34788D22aE6b7d55016e1f
address internal constant UI_POOL_DATA_PROVIDER = 0x1DcDA4de2Bf6c7AD9a34788D22aE6b7d55016e1f;
// https://explorer.harmony.one/address/0xeC6118C69af50660231108059ab98CD0cF9a6eA1
address internal constant UI_POOL_DATA_PROVIDER = 0xeC6118C69af50660231108059ab98CD0cF9a6eA1;

// https://explorer.harmony.one/address/0xBc790382B3686abffE4be14A030A96aC6154023a
address internal constant WALLET_BALANCE_PROVIDER = 0xBc790382B3686abffE4be14A030A96aC6154023a;
Expand Down
2 changes: 1 addition & 1 deletion src/ts/AaveAddressBook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export * as AaveV3Scroll from './AaveV3Scroll';
export * as AaveV3ScrollSepolia from './AaveV3ScrollSepolia';
export * as AaveV3FantomTestnet from './AaveV3FantomTestnet';
export * as AaveV3Fantom from './AaveV3Fantom';
export * as AaveV3Harmony from './AaveV3Harmony';
export * as MiscArbitrum from './MiscArbitrum';
export * as MiscArbitrumSepolia from './MiscArbitrumSepolia';
export * as MiscAvalanche from './MiscAvalanche';
Expand Down Expand Up @@ -88,4 +89,3 @@ export {IStkAaveToken_ABI} from './abis/IStkAaveToken';
export {IATokenWithDelegation_ABI} from './abis/IATokenWithDelegation';
export {IStaticATokenFactory_ABI} from './abis/IStaticATokenFactory';
export {IStaticATokenLM_ABI} from './abis/IStaticATokenLM';
export * as AaveV3Harmony from './AaveV3Harmony';
13 changes: 8 additions & 5 deletions src/ts/AaveV3Harmony.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,18 @@ export const POOL_ADDRESSES_PROVIDER = '0xa97684ead0e402dC232d5A977953DF7ECBaB3C
// IPool https://explorer.harmony.one/address/0x794a61358D6845594F94dc1DB02A252b5b4814aD
export const POOL = '0x794a61358D6845594F94dc1DB02A252b5b4814aD';

// https://explorer.harmony.one/address/0xDF9e4ABdbd94107932265319479643D3B05809dc
export const POOL_IMPL = '0xDF9e4ABdbd94107932265319479643D3B05809dc';

// IPoolConfigurator https://explorer.harmony.one/address/0x8145eddDf43f50276641b55bd3AD95944510021E
export const POOL_CONFIGURATOR = '0x8145eddDf43f50276641b55bd3AD95944510021E';

// https://explorer.harmony.one/address/0xD6FA681E22306b0F4E605B979b7c9a1dFa865ade
export const POOL_CONFIGURATOR_IMPL = '0xD6FA681E22306b0F4E605B979b7c9a1dFa865ade';

// IAaveOracle https://explorer.harmony.one/address/0x3C90887Ede8D65ccb2777A5d577beAb2548280AD
export const ORACLE = '0x3C90887Ede8D65ccb2777A5d577beAb2548280AD';

// https://explorer.harmony.one/address/0x0000000000000000000000000000000000000000
export const PRICE_ORACLE_SENTINEL = '0x0000000000000000000000000000000000000000';

// IPoolDataProvider https://explorer.harmony.one/address/0x69FA688f1Dc47d4B5d8029D5a35FB7a548310654
export const AAVE_PROTOCOL_DATA_PROVIDER = '0x69FA688f1Dc47d4B5d8029D5a35FB7a548310654';

Expand Down Expand Up @@ -47,8 +50,8 @@ export const POOL_ADDRESSES_PROVIDER_REGISTRY = '0x770ef9f4fe897e59daCc474EF1123
// https://explorer.harmony.one/address/0xf7a60467aBb8A3240A0382b22E1B03c7d4F59Da5
export const UI_INCENTIVE_DATA_PROVIDER = '0xf7a60467aBb8A3240A0382b22E1B03c7d4F59Da5';

// https://explorer.harmony.one/address/0x1DcDA4de2Bf6c7AD9a34788D22aE6b7d55016e1f
export const UI_POOL_DATA_PROVIDER = '0x1DcDA4de2Bf6c7AD9a34788D22aE6b7d55016e1f';
// https://explorer.harmony.one/address/0xeC6118C69af50660231108059ab98CD0cF9a6eA1
export const UI_POOL_DATA_PROVIDER = '0xeC6118C69af50660231108059ab98CD0cF9a6eA1';

// https://explorer.harmony.one/address/0xBc790382B3686abffE4be14A030A96aC6154023a
export const WALLET_BALANCE_PROVIDER = '0xBc790382B3686abffE4be14A030A96aC6154023a';
Expand Down
168 changes: 166 additions & 2 deletions src/ts/tokenlist.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5816,7 +5816,171 @@ export const tokenlist = {
underlying: '0xae75A438b2E0cB8Bb01Ec1E1e376De11D44477CC',
},
},
{
chainId: 1666600000,
address: '0xEf977d2f931C1978Db5F6747666fa1eACB0d0339',
name: 'Dai Stablecoin',
decimals: 18,
symbol: 'ONE_DAI',
tags: ['underlying'],
},
{
chainId: 1666600000,
address: '0x82E64f49Ed5EC1bC6e43DAD4FC8Af9bb3A2312EE',
name: 'Aave Harmony DAI',
decimals: 18,
symbol: 'aHarDAI',
tags: ['aTokenV3', 'aaveV3'],
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0xEf977d2f931C1978Db5F6747666fa1eACB0d0339',
},
},
{
chainId: 1666600000,
address: '0x218532a12a389a4a92fC0C5Fb22901D1c19198aA',
name: 'ChainLink Token',
decimals: 18,
symbol: 'LINK',
tags: ['underlying'],
logoURI: 'ipfs://QmRtU7R1eZcfFTgBLX57zPufc3HFhW2BG5WyikqUfNdJqV',
},
{
chainId: 1666600000,
address: '0x191c10Aa4AF7C30e871E70C95dB0E4eb77237530',
name: 'Aave Harmony LINK',
decimals: 18,
symbol: 'aHarLINK',
tags: ['aTokenV3', 'aaveV3'],
logoURI: 'ipfs://QmaqAt4UdDdo1mX4JRbYp1bz6VL84acFeRS3B3DjCYver2',
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0x218532a12a389a4a92fC0C5Fb22901D1c19198aA',
},
},
{
chainId: 1666600000,
address: '0x985458E523dB3d53125813eD68c274899e9DfAb4',
name: 'USD Coin',
decimals: 6,
symbol: 'ONE_USDC',
tags: ['underlying'],
},
{
chainId: 1666600000,
address: '0x625E7708f30cA75bfd92586e17077590C60eb4cD',
name: 'Aave Harmony USDC',
decimals: 6,
symbol: 'aHarUSDC',
tags: ['aTokenV3', 'aaveV3'],
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0x985458E523dB3d53125813eD68c274899e9DfAb4',
},
},
{
chainId: 1666600000,
address: '0x3095c7557bCb296ccc6e363DE01b760bA031F2d9',
name: 'Wrapped BTC',
decimals: 8,
symbol: 'ONE_WBTC',
tags: ['underlying'],
},
{
chainId: 1666600000,
address: '0x078f358208685046a11C85e8ad32895DED33A249',
name: 'Aave Harmony WBTC',
decimals: 8,
symbol: 'aHarWBTC',
tags: ['aTokenV3', 'aaveV3'],
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0x3095c7557bCb296ccc6e363DE01b760bA031F2d9',
},
},
{
chainId: 1666600000,
address: '0x6983D1E6DEf3690C4d616b13597A09e6193EA013',
name: 'ETH',
decimals: 18,
symbol: 'ONE_ETH',
tags: ['underlying'],
},
{
chainId: 1666600000,
address: '0xe50fA9b3c56FfB159cB0FCA61F5c9D750e8128c8',
name: 'Aave Harmony WETH',
decimals: 18,
symbol: 'aHarWETH',
tags: ['aTokenV3', 'aaveV3'],
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0x6983D1E6DEf3690C4d616b13597A09e6193EA013',
},
},
{
chainId: 1666600000,
address: '0x3C2B8Be99c50593081EAA2A724F0B8285F5aba8f',
name: 'Tether USD',
decimals: 6,
symbol: 'ONE_USDT',
tags: ['underlying'],
},
{
chainId: 1666600000,
address: '0x6ab707Aca953eDAeFBc4fD23bA73294241490620',
name: 'Aave Harmony USDT',
decimals: 6,
symbol: 'aHarUSDT',
tags: ['aTokenV3', 'aaveV3'],
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0x3C2B8Be99c50593081EAA2A724F0B8285F5aba8f',
},
},
{
chainId: 1666600000,
address: '0xcF323Aad9E522B93F11c352CaA519Ad0E14eB40F',
name: 'Aave Token',
decimals: 18,
symbol: 'ONE_AAVE',
tags: ['underlying'],
},
{
chainId: 1666600000,
address: '0xf329e36C7bF6E5E86ce2150875a84Ce77f477375',
name: 'Aave Harmony AAVE',
decimals: 18,
symbol: 'aHarAAVE',
tags: ['aTokenV3', 'aaveV3'],
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0xcF323Aad9E522B93F11c352CaA519Ad0E14eB40F',
},
},
{
chainId: 1666600000,
address: '0xcF664087a5bB0237a0BAd6742852ec6c8d69A27a',
name: 'Wrapped ONE',
decimals: 18,
symbol: 'WONE',
tags: ['underlying'],
logoURI: 'ipfs://QmWjbWEfnaYC8FKHeSuQGs71PZqFwdBxJ9KRSVTUXDu263',
},
{
chainId: 1666600000,
address: '0x6d80113e533a2C0fe82EaBD35f1875DcEA89Ea97',
name: 'Aave Harmony WONE',
decimals: 18,
symbol: 'aHarWONE',
tags: ['aTokenV3', 'aaveV3'],
logoURI: 'ipfs://QmRmMxPWKnEP8bdvLvg3W5BjiTo5dAhoN1va3RJauScXHS',
extensions: {
pool: '0x794a61358D6845594F94dc1DB02A252b5b4814aD',
underlying: '0xcF664087a5bB0237a0BAd6742852ec6c8d69A27a',
},
},
],
version: {major: 3, minor: 0, patch: 15},
timestamp: '2024-04-22T06:01:02.747Z',
version: {major: 3, minor: 0, patch: 16},
timestamp: '2024-04-23T08:44:32.311Z',
};
Loading

0 comments on commit cc7b565

Please sign in to comment.